#26231 closed Bug (fixed)
Hint for non-staff users on admin page refers wrong attribute for username.
| Reported by: | Sjoerd Job Postmus | Owned by: | nobody |
|---|---|---|---|
| Component: | contrib.admin | Version: | 1.9 |
| Severity: | Normal | Keywords: | |
| Cc: | Triage Stage: | Accepted | |
| Has patch: | yes | Needs documentation: | no |
| Needs tests: | yes | Patch needs improvement: | no |
| Easy pickings: | yes | UI/UX: | no |
Description
In commit 635ffc3c37d58eb96ae17d5389dd50bf635413c6 a block was introduced accessing username as request.user.username, but it should be accessed using request.user.get_username. This breaks on custom models which do not have a username attribute or property.
(marking with Has patch, because I submitted one on github already).
Note:
See TracTickets
for help on using tickets.
PR needs a test.