Skip to content
Snippets Groups Projects
Commit 7b0515d8 authored by Sigurd's avatar Sigurd
Browse files

new check

changed serialiser to form
parent ed5081ac
No related branches found
No related tags found
No related merge requests found
Pipeline #170715 failed with stage
in 24 seconds
......@@ -36,6 +36,9 @@ class UserSerializer(serializers.HyperlinkedModelSerializer):
password = data.get("password")
password1 = data.get("password1")
if password != password1():
raise forms.ValidationError("The passwords must match")
try:
password_validation.validate_password(password)
except forms.ValidationError as error:
......
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