Browse Source

remove default otp value

master
Mohsen Taba 2 weeks ago
parent
commit
afd16a2aa4
  1. 4
      apps/account/views/user.py

4
apps/account/views/user.py

@ -332,9 +332,7 @@ class UserVerifyView(CreateAPIView):
}, status=status.HTTP_201_CREATED)
def valied_code(self, current_code, save_code):
if (current_code and save_code) and (str(current_code) != str(save_code)):
if str(current_code) in ["11111", "111111"]:
return current_code
if not current_code or not save_code or str(current_code) != str(save_code):
raise ValidationError({"code": "code notfound"})
return current_code

Loading…
Cancel
Save