diff --git a/taiga/projects/attachments/api.py b/taiga/projects/attachments/api.py index 987a721c..e1195e2f 100644 --- a/taiga/projects/attachments/api.py +++ b/taiga/projects/attachments/api.py @@ -34,7 +34,6 @@ from taiga.users.models import User from taiga.projects.notifications import WatchedResourceMixin from taiga.projects.history import HistoryResourceMixin - from . import permissions from . import serializers from . import models @@ -47,6 +46,12 @@ class BaseAttachmentViewSet(HistoryResourceMixin, WatchedResourceMixin, ModelCru content_type = None + def update(self, *args, **kwargs): + partial = kwargs.get("partial", False) + if not partial: + raise exc.NotSupported("Non partial updates not supported") + return super().update(*args, **kwargs) + def get_content_type(self): app_name, model = self.content_type.split(".", 1) return get_object_or_404(ContentType, app_label=app_name, model=model)