summaryrefslogtreecommitdiff
path: root/docs/topics/auth.txt
diff options
context:
space:
mode:
authorRussell Keith-Magee <russell@keith-magee.com>2012-10-06 12:46:35 +0800
committerRussell Keith-Magee <russell@keith-magee.com>2012-10-06 12:46:35 +0800
commit12f39be508cab95a9841987c3df589ef69de706e (patch)
tree28738eceddc86d763a28ce820004e91090f85af0 /docs/topics/auth.txt
parentb9039268a17b06e7fe069721e99f6d69181c344d (diff)
Fixed #19074 -- Corrected some minor issues with the new custom User docs.
Thanks to Bradley Ayers for the review.
Diffstat (limited to 'docs/topics/auth.txt')
-rw-r--r--docs/topics/auth.txt20
1 files changed, 10 insertions, 10 deletions
diff --git a/docs/topics/auth.txt b/docs/topics/auth.txt
index f9c9057baa..bbe6d6ec33 100644
--- a/docs/topics/auth.txt
+++ b/docs/topics/auth.txt
@@ -2074,20 +2074,20 @@ authentication app::
Creates and saves a superuser with the given email, date of
birth and password.
"""
- u = self.create_user(username,
- password=password,
- date_of_birth=date_of_birth
- )
- u.is_admin = True
- u.save(using=self._db)
- return u
+ user = self.create_user(username,
+ password=password,
+ date_of_birth=date_of_birth
+ )
+ user.is_admin = True
+ user.save(using=self._db)
+ return user
class MyUser(AbstractBaseUser):
email = models.EmailField(
- verbose_name='email address',
- max_length=255
- )
+ verbose_name='email address',
+ max_length=255
+ )
date_of_birth = models.DateField()
is_active = models.BooleanField(default=True)
is_admin = models.BooleanField(default=False)