You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I noticed that AbstractEmailUser does not reproduce the .clean() method that Django's AbstractUser provides, which means normalize_email() (lowercasify the domain portion) is not being invoked on save.
I've submitted a pull request with a fix, on the assumption that calling Django's normalize_email() everywhere is the preferred outcome, and does not conflict with approaches discussed in #11
I noticed that AbstractEmailUser does not reproduce the
.clean()
method that Django's AbstractUser provides, which meansnormalize_email()
(lowercasify the domain portion) is not being invoked on save.https://github.com/django/django/blob/master/django/contrib/auth/models.py#L363-L365:
I would assume that this is deliberate, but authtools' implementation of
UserManager.create_user()
does includenormalize_email()
https://github.com/fusionbox/django-authtools/blob/master/authtools/models.py#L12-L17
Which means that users created with
manage.py createsuperuser
will have their emails normalized, but users created through the Django Admin will not.The text was updated successfully, but these errors were encountered: