mirror of
https://gitlab2.federez.net/re2o/re2o
synced 2024-12-25 08:23:46 +00:00
Fix la creation superuser broken
This commit is contained in:
parent
d5c0068733
commit
160b95c836
1 changed files with 4 additions and 1 deletions
|
@ -143,9 +143,10 @@ class UserManager(BaseUserManager):
|
||||||
if not linux_user_check(pseudo):
|
if not linux_user_check(pseudo):
|
||||||
raise ValueError('Username shall only contain [a-z0-9-]')
|
raise ValueError('Username shall only contain [a-z0-9-]')
|
||||||
|
|
||||||
user = self.model(
|
user = Adherent(
|
||||||
pseudo=pseudo,
|
pseudo=pseudo,
|
||||||
surname=surname,
|
surname=surname,
|
||||||
|
name=surname,
|
||||||
email=self.normalize_email(email),
|
email=self.normalize_email(email),
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@ -824,6 +825,8 @@ class Adherent(User):
|
||||||
null=True
|
null=True
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
def get_instance(adherentid, *args, **kwargs):
|
def get_instance(adherentid, *args, **kwargs):
|
||||||
"""Try to find an instance of `Adherent` with the given id.
|
"""Try to find an instance of `Adherent` with the given id.
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue