fix: page labels update (#532)

This commit is contained in:
pablohashescobar 2023-03-25 23:57:06 +05:30 committed by GitHub
parent 32ab7951f7
commit 69387ffd8c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -67,7 +67,7 @@ class PageSerializer(BaseSerializer):
def update(self, instance, validated_data):
labels = validated_data.pop("labels_list", None)
if labels is not None:
PageLabel.objects.filter(issue=instance).delete()
PageLabel.objects.filter(page=instance).delete()
PageLabel.objects.bulk_create(
[
PageLabel(