Commit 5f35768f authored by Flavio TARSETTI's avatar Flavio TARSETTI

[ui][registration][forms] fix supervisor crash on sign-up

Fixes #568
parent 4200e85e
Pipeline #42854 passed with stage
in 16 minutes and 33 seconds
......@@ -433,7 +433,7 @@ class RegistrationSupervisorForm(forms.Form):
"""
username = self.cleaned_data["username"]
if User.objects.get(username__iexact=username).exists():
if User.objects.filter(username__iexact=username).exists():
raise forms.ValidationError(
_(u"This username is already taken. Please choose another.")
)
......
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