removed registration_complete from forgot password
This commit is contained in:
@@ -270,7 +270,7 @@ class RegistrationPasswordView(APIView):
|
||||
return ApiResponse.error(**error_response)
|
||||
try:
|
||||
principal = serializer.save()
|
||||
principal.register_complete = True
|
||||
# principal.register_complete = True
|
||||
principal.save()
|
||||
except Exception as e:
|
||||
error_response = {
|
||||
@@ -448,6 +448,8 @@ class LoginView(APIView):
|
||||
|
||||
otp_instance.is_used = True
|
||||
otp_instance.save()
|
||||
principal.email_verified = True
|
||||
principal.save()
|
||||
|
||||
return self._login_success(principal)
|
||||
|
||||
@@ -465,7 +467,7 @@ class LoginView(APIView):
|
||||
|
||||
def _login_success(self, principal):
|
||||
try:
|
||||
principal.email_verified = True
|
||||
# principal.email_verified = True
|
||||
principal.last_login = timezone.localtime(timezone.now())
|
||||
principal.save()
|
||||
except Exception as e:
|
||||
|
||||
Reference in New Issue
Block a user