mirror of
https://github.com/netbox-community/netbox.git
synced 2024-05-10 07:54:54 +00:00
Fix serialization of tags for REST API updates
This commit is contained in:
@ -108,6 +108,10 @@ class TaggedObjectSerializer(serializers.Serializer):
|
||||
|
||||
def update(self, instance, validated_data):
|
||||
tags = validated_data.pop('tags', [])
|
||||
|
||||
# Cache tags on instance for change logging
|
||||
instance._tags = tags
|
||||
|
||||
instance = super().update(instance, validated_data)
|
||||
|
||||
return self._save_tags(instance, tags)
|
||||
|
Reference in New Issue
Block a user