Reformat code
This commit is contained in:
parent
a6a6f8213b
commit
47b714101b
2 changed files with 5 additions and 3 deletions
|
@ -19,10 +19,12 @@ class LoginForm(forms.Form):
|
|||
is_auth = authenticate(username=email, password=password)
|
||||
if not is_auth:
|
||||
raise forms.ValidationError(
|
||||
_("Your username and/or password were incorrect."))
|
||||
_("Your username and/or password were incorrect.")
|
||||
)
|
||||
elif is_auth.validated == 0:
|
||||
raise forms.ValidationError(
|
||||
_("Your account is not activated yet."))
|
||||
_("Your account is not activated yet.")
|
||||
)
|
||||
return self.cleaned_data
|
||||
|
||||
def clean_email(self):
|
||||
|
|
|
@ -17,4 +17,4 @@ urlpatterns = [
|
|||
path('reset/<str:user>/<str:token>/', ResetRequest.as_view()),
|
||||
path('reset/', ResetRequest.as_view(), name="reset"),
|
||||
path('', Index.as_view(), name="index"),
|
||||
]
|
||||
]
|
Loading…
Reference in a new issue