summaryrefslogtreecommitdiff
path: root/docs/topics/auth
diff options
context:
space:
mode:
authorchillaranand <anand21nanda@gmail.com>2017-01-22 12:27:14 +0530
committerTim Graham <timograham@gmail.com>2017-01-25 11:53:05 -0500
commitdc165ec8e5698ffc6dee6b510f1f92c9fd7467fe (patch)
treeebcd5f708528b2aec195f9a97d28bd85653aa7dc /docs/topics/auth
parent2d96c027f5eb32c2c09bd57df2240ae1d343b98e (diff)
Refs #23919 -- Replaced super(ClassName, self) with super() in docs.
Diffstat (limited to 'docs/topics/auth')
-rw-r--r--docs/topics/auth/customizing.txt2
-rw-r--r--docs/topics/auth/passwords.txt2
2 files changed, 2 insertions, 2 deletions
diff --git a/docs/topics/auth/customizing.txt b/docs/topics/auth/customizing.txt
index c4fd73cebc..b3c3335a73 100644
--- a/docs/topics/auth/customizing.txt
+++ b/docs/topics/auth/customizing.txt
@@ -1111,7 +1111,7 @@ code would be required in the app's ``admin.py`` file::
def save(self, commit=True):
# Save the provided password in hashed format
- user = super(UserCreationForm, self).save(commit=False)
+ user = super().save(commit=False)
user.set_password(self.cleaned_data["password1"])
if commit:
user.save()
diff --git a/docs/topics/auth/passwords.txt b/docs/topics/auth/passwords.txt
index 128a2906cb..9cf868ca21 100644
--- a/docs/topics/auth/passwords.txt
+++ b/docs/topics/auth/passwords.txt
@@ -292,7 +292,7 @@ First, we'll add the custom hasher:
algorithm = 'pbkdf2_wrapped_sha1'
def encode_sha1_hash(self, sha1_hash, salt, iterations=None):
- return super(PBKDF2WrappedSHA1PasswordHasher, self).encode(sha1_hash, salt, iterations)
+ return super().encode(sha1_hash, salt, iterations)
def encode(self, password, salt, iterations=None):
_, _, sha1_hash = SHA1PasswordHasher().encode(password, salt).split('$', 2)