Skip to content
Browse files

Fixed #15322 -- Removed a redundant check in admin logins. Thanks to …

…melinath for the report.

git-svn-id: bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
1 parent 670f4d9 commit 127725c56062659c284b18ca097db99be863227b @freakboy3742 freakboy3742 committed
Showing with 1 addition and 1 deletion.
  1. +1 −1 django/contrib/admin/
2 django/contrib/admin/
@@ -25,7 +25,7 @@ def clean(self):
if username and password:
self.user_cache = authenticate(username=username, password=password)
if self.user_cache is None:
- if username is not None and u'@' in username:
+ if u'@' in username:
# Mistakenly entered e-mail address instead of username? Look it up.
user = User.objects.get(email=username)

0 comments on commit 127725c

Please sign in to comment.
Something went wrong with that request. Please try again.