This commit is contained in:
Jonathan Baecker 2020-05-08 15:19:44 +02:00
parent 08ecc50d71
commit 28191883a2

View File

@ -47,13 +47,6 @@ class GuiSettingsSerializer(serializers.ModelSerializer):
model = GuiSettings model = GuiSettings
fields = '__all__' fields = '__all__'
def get_fields(self, *args, **kwargs):
fields = super().get_fields(*args, **kwargs)
request = self.context.get('request')
if request is not None and not request.parser_context.get('kwargs'):
fields.pop('id', None)
return fields
class MessengerSerializer(serializers.ModelSerializer): class MessengerSerializer(serializers.ModelSerializer):
class Meta: class Meta: