From 3f79f1fd3adf8900d6fa6dc93b86f585ba9152b3 Mon Sep 17 00:00:00 2001 From: robines Date: Fri, 22 Nov 2024 19:20:46 +0100 Subject: [PATCH] ruff --- backend/samfundet/serializers.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/backend/samfundet/serializers.py b/backend/samfundet/serializers.py index d8e3447d0..d19f08ce7 100644 --- a/backend/samfundet/serializers.py +++ b/backend/samfundet/serializers.py @@ -241,13 +241,13 @@ class ChangePasswordSerializer(serializers.Serializer): new_password = serializers.CharField(required=True) def validate_current_password(self, value: str) -> str: - user = self.context["request"].user + user = self.context['request'].user if not user.check_password(value): raise serializers.ValidationError('Incorrect current password') return value def validate_new_password(self, value: str) -> str: - user = self.context["request"].user + user = self.context['request'].user validate_password(value, user) return value