MCPcopy Create free account
hub / github.com/lesspass/lesspass / EncryptedPasswordProfileSerializer

Class EncryptedPasswordProfileSerializer

containers/backend/api/serializers.py:30–45  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

28
29
30class EncryptedPasswordProfileSerializer(serializers.ModelSerializer):
31 class Meta:
32 model = models.EncryptedPasswordProfile
33 fields = (
34 "id",
35 "password_profile",
36 "created",
37 "modified",
38 )
39 read_only_fields = ("created", "modified")
40
41 def create(self, validated_data):
42 user = self.context["request"].user
43 return models.EncryptedPasswordProfile.objects.create(
44 user=user, **validated_data
45 )
46
47
48class BackwardCompatibleTokenObtainPairSerializer(TokenObtainPairSerializer):

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected