X-Git-Url: https://git.openstreetmap.org./osqa.git/blobdiff_plain/1a949f7c97dc2f34c135f5cdf088df2927d3d652..9e80d89162cb0384c388a44fad0ac9e3fca5be5e:/forum_modules/localauth/forms.py diff --git a/forum_modules/localauth/forms.py b/forum_modules/localauth/forms.py index 06fcb79..a3fd992 100644 --- a/forum_modules/localauth/forms.py +++ b/forum_modules/localauth/forms.py @@ -47,7 +47,7 @@ class ClassicLoginForm(forms.Form): def _clean_nonempty_field(self,field): value = None if field in self.cleaned_data: - value = str(self.cleaned_data[field]).strip() + value = self.cleaned_data[field].strip() if value == '': value = None self.cleaned_data[field] = value @@ -92,7 +92,7 @@ class ClassicLoginForm(forms.Form): error_list.append(_('Please enter user name')) if len(error_list) > 0: self._errors['__all__'] = forms.util.ErrorList(error_list) - + return self.cleaned_data def get_user(self):