Hi everyone!<div><br></div><div>I am trying to develop a new feature to horizon, I want to users can update their own password.</div><div>I used this:</div><div><br></div><div><div>from horizon import api</div></div><div><br>
</div><div><div>api.user_update_password(</div><div>    request,</div><div>    <a href="http://request.user.id">request.user.id</a>,</div><div>    form.cleaned_data['new_password'],</div><div>    admin=True</div><div>
)</div></div><div><br></div><div>But  the user is logged out because in keystone.py there is this: </div><div><br></div><div><div>if not user.is_admin():</div><div>            raise exceptions.NotAuthorized</div></div><div>
<br></div><div>So, Only the user admin can use that method.</div><div><br></div><div>How can I be able to use this method with a normal user, or do you recommend to query the database directly to modify the password in the user table.</div>
<div><br></div><div>Thanks in advance!</div>