From c8f98a9bc20580df87e6ffb91c3065ce45d3d194 Mon Sep 17 00:00:00 2001 From: Nikhil <118773738+pablohashescobar@users.noreply.github.com> Date: Fri, 27 Oct 2023 15:31:15 +0530 Subject: [PATCH] chore: make module create and list endpoint response structure simillar (#2524) --- apiserver/plane/api/views/module.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/apiserver/plane/api/views/module.py b/apiserver/plane/api/views/module.py index 45c52c0bf..e5bda6b65 100644 --- a/apiserver/plane/api/views/module.py +++ b/apiserver/plane/api/views/module.py @@ -149,6 +149,9 @@ class ModuleViewSet(BaseViewSet): if serializer.is_valid(): serializer.save() + + module = Module.objects.get(pk=serializer.data["id"]) + serializer = ModuleSerializer(module) return Response(serializer.data, status=status.HTTP_201_CREATED) return Response(serializer.errors, status=status.HTTP_400_BAD_REQUEST)