Commit a7b5ef8e authored by okhin's avatar okhin 🚴

Let's raise validation exceptions

parent 14df4ac6
Pipeline #847 failed with stages
in 46 seconds
......@@ -17,6 +17,6 @@ class FeedbackViewSet(viewsets.ViewSet):
@csrf_exempt
def create(self, request, campaign_pk=None):
serializer = FeedbackSerializer(data=request.data)
serializer.is_valid()
serializer.is_valid(raise_exception=True)
feedback = serializer.create(serializer.validated_data)
return Response(feedback.id)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment