Opened 6 years ago

Closed 6 years ago

#29686 closed Cleanup/optimization (fixed)

Make UserAdmin.user_change_password() pass object to has_change_permission()

Reported by: Alexander Todorov Owned by: nobody
Component: contrib.auth Version: 2.1
Severity: Normal Keywords:
Cc: Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description (last modified by Tim Graham)

This makes overriding user_change_password() and mangling permissions easier because we have access to the object.

For example when you'd like to use the admin panel to allow users to change their own passwords but not see the list of all users or anything else.

PR

Change History (2)

comment:1 by Tim Graham, 6 years ago

Description: modified (diff)
Has patch: set
Summary: contrib.auth.admin - user_change_password() method send object to has_change_permission()Make UserAdmin.user_change_password() pass object to has_change_permission()
Triage Stage: UnreviewedAccepted
Type: New featureCleanup/optimization

comment:2 by Tim Graham <timograham@…>, 6 years ago

Resolution: fixed
Status: newclosed

In 53ebd4cb:

Fixed #29686 -- Made UserAdmin.user_change_password() pass user to has_change_permission().

Note: See TracTickets for help on using tickets.
Back to Top