mirror of
https://github.com/django/django.git
synced 2025-08-11 06:18:21 +00:00
[1.5.x] Fixed #20394 - Clarified argument of get_user in docs
Backport of 1172bef998
from master.
This commit is contained in:
parent
cac0f7b72e
commit
be6e7ff6eb
1 changed files with 2 additions and 1 deletions
|
@ -89,7 +89,8 @@ An authentication backend is a class that implements two required methods:
|
||||||
optional permission related :ref:`authorization methods <authorization_methods>`.
|
optional permission related :ref:`authorization methods <authorization_methods>`.
|
||||||
|
|
||||||
The ``get_user`` method takes a ``user_id`` -- which could be a username,
|
The ``get_user`` method takes a ``user_id`` -- which could be a username,
|
||||||
database ID or whatever -- and returns a ``User`` object.
|
database ID or whatever, but has to be the primary key of your ``User`` object
|
||||||
|
-- and returns a ``User`` object.
|
||||||
|
|
||||||
The ``authenticate`` method takes credentials as keyword arguments. Most of
|
The ``authenticate`` method takes credentials as keyword arguments. Most of
|
||||||
the time, it'll just look like this::
|
the time, it'll just look like this::
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue