Commit f30ed7e6 authored by Sofia Papagiannaki's avatar Sofia Papagiannaki
Browse files

Fix infinite loop in case another user with the same email already exists

parent e8c77add
...@@ -498,13 +498,8 @@ class AstakosUser(User): ...@@ -498,13 +498,8 @@ class AstakosUser(User):
if not if not
# set username # set username
while not self.username: self.username =
username =
except AstakosUser.DoesNotExist:
self.username = username
self.validate_unique_email_isactive() self.validate_unique_email_isactive()
if self.is_active and self.activation_sent: if self.is_active and self.activation_sent:
# reset the activation sent # reset the activation sent
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment