SciPost Code Repository

Skip to content
Snippets Groups Projects
Commit 53f25400 authored by Jorran de Wit's avatar Jorran de Wit
Browse files

Return right form data field

parent a150264c
No related branches found
No related tags found
No related merge requests found
...@@ -80,7 +80,7 @@ class RegistrationForm(forms.Form): ...@@ -80,7 +80,7 @@ class RegistrationForm(forms.Form):
if self.cleaned_data['password'] != self.cleaned_data['password_verif']: if self.cleaned_data['password'] != self.cleaned_data['password_verif']:
self.add_error('password', 'Your passwords must match') self.add_error('password', 'Your passwords must match')
self.add_error('password_verif', 'Your passwords must match') self.add_error('password_verif', 'Your passwords must match')
return self.cleaned_data.get('password', '') return self.cleaned_data.get('password_verif', '')
def clean_username(self): def clean_username(self):
if User.objects.filter(username=self.cleaned_data['username']).exists(): if User.objects.filter(username=self.cleaned_data['username']).exists():
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment