From 5f234a54f16674f67bb73cef1f24d5cb5017b41b Mon Sep 17 00:00:00 2001 From: Jakub K Date: Fri, 22 Dec 2023 18:59:26 +0100 Subject: [PATCH] fix UserManager --- core/models.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/models.py b/core/models.py index 50fbd7d..3d29c75 100644 --- a/core/models.py +++ b/core/models.py @@ -17,7 +17,7 @@ class MyUserManager(BaseUserManager): def create_superuser(self, email, password=None, **extra_fields): extra_fields.setdefault('is_staff', True) extra_fields.setdefault('is_superuser', True) - + email = self.normalize_email(email) if extra_fields.get('is_staff') is not True: raise ValueError(_('Superuser must have is_staff=True.')) if extra_fields.get('is_superuser') is not True: