summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorRussell Keith-Magee <russell@keith-magee.com>2013-02-15 09:00:55 +0800
committerRussell Keith-Magee <russell@keith-magee.com>2013-02-15 09:00:55 +0800
commitf5e4a699ca0f58818acbdf9081164060cee910fa (patch)
treee4cbef9c11d69c7d393dcf5533f6989a91928503 /docs
parentf179a5198e05e1be8ba8be87c1f0e1a8924cf005 (diff)
Fixed #19822 -- Added validation for uniqueness on USERNAME_FIELD on custom User models.
Thanks to Claude Peroz for the draft patch.
Diffstat (limited to 'docs')
-rw-r--r--docs/topics/auth/customizing.txt5
1 files changed, 4 insertions, 1 deletions
diff --git a/docs/topics/auth/customizing.txt b/docs/topics/auth/customizing.txt
index 7f1eff6624..d1ce6eb7dc 100644
--- a/docs/topics/auth/customizing.txt
+++ b/docs/topics/auth/customizing.txt
@@ -492,7 +492,10 @@ password resets. You must then provide some key implementation details:
A string describing the name of the field on the User model that is
used as the unique identifier. This will usually be a username of
some kind, but it can also be an email address, or any other unique
- identifier. In the following example, the field `identifier` is used
+ identifier. The field *must* be unique (i.e., have ``unique=True``
+ set in it's definition).
+
+ In the following example, the field `identifier` is used
as the identifying field::
class MyUser(AbstractBaseUser):