Skip to content

Commit 6b1e246

Browse files
committed
Another change related to permitting '@' in the usernames.
- Legacy-Id: 2057
1 parent b9f824c commit 6b1e246

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

django/contrib/admin/sites.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -305,13 +305,13 @@ def login(self, request):
305305
try:
306306
user = User.objects.get(email=username)
307307
except (User.DoesNotExist, User.MultipleObjectsReturned):
308-
message = _("Usernames cannot contain the '@' character.")
308+
pass
309309
else:
310310
if user.check_password(password):
311311
message = _("Your e-mail address is not your username."
312312
" Try '%s' instead.") % user.username
313313
else:
314-
message = _("Usernames cannot contain the '@' character.")
314+
pass
315315
return self.display_login_form(request, message)
316316

317317
# The user data is correct; log in the user in and continue.

0 commit comments

Comments
 (0)