From 9ea01d4d938ba90c99adfe4c492f9c8cdf4cd60d Mon Sep 17 00:00:00 2001 From: Tom Hacohen Date: Mon, 13 Jul 2020 11:15:42 +0300 Subject: [PATCH] CollectionMemberSerializer: change the user field to be read only. --- django_etebase/serializers.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/django_etebase/serializers.py b/django_etebase/serializers.py index 7fe5050..13199b3 100644 --- a/django_etebase/serializers.py +++ b/django_etebase/serializers.py @@ -255,7 +255,7 @@ class CollectionMemberSerializer(serializers.ModelSerializer): username = serializers.SlugRelatedField( source='user', slug_field=User.USERNAME_FIELD, - queryset=User.objects + read_only=True, ) class Meta: