Mark email as read only for user details

This commit is contained in:
Jeppe Vesterbæk 2015-02-25 16:06:46 +01:00
parent 200dad30fb
commit 846040259a

View File

@ -46,6 +46,7 @@ class UserDetailsSerializer(serializers.ModelSerializer):
class Meta: class Meta:
model = get_user_model() model = get_user_model()
fields = ('username', 'email', 'first_name', 'last_name') fields = ('username', 'email', 'first_name', 'last_name')
read_only_fields = ('email', )
class PasswordResetSerializer(serializers.Serializer): class PasswordResetSerializer(serializers.Serializer):