Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion apps/api/plane/api/views/module.py
Original file line number Diff line number Diff line change
Expand Up @@ -410,7 +410,7 @@ def patch(self, request, slug, project_id, pk):
{"error": "Archived module cannot be edited"},
status=status.HTTP_400_BAD_REQUEST,
)
serializer = ModuleSerializer(module, data=request.data, context={"project_id": project_id}, partial=True)
serializer = ModuleUpdateSerializer(module, data=request.data, context={"project_id": project_id}, partial=True)
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Update endpoint returns incomplete response data

Medium Severity

The patch method now returns ModuleUpdateSerializer.data directly, but this serializer only includes a limited subset of fields (name, description, dates, status, lead, members, external_source, external_id). The response is missing important fields like id, total_issues, completed_issues, and other computed metrics. The create method follows the correct pattern by re-fetching the module and using ModuleSerializer for the response. The OpenAPI documentation also specifies ModuleSerializer as the response type, creating an inconsistency. API consumers expecting the full module data in the update response will receive incomplete data.

Additional Locations (1)

Fix in Cursor Fix in Web

if serializer.is_valid():
if (
request.data.get("external_id")
Expand Down
Loading