patch chat

This commit is contained in:
2024-01-08 17:20:15 +01:00
parent 58d20920ea
commit 478456a199
8 changed files with 27 additions and 22 deletions

View File

@ -26,8 +26,7 @@ class BlocksView(APIView):
blocks = BlockModel.objects.filter(blocker=request.user.pk)
if (blocks):
return Response(serializers.serialize("json", BlockModel.objects.filter(blocker=request.user.pk)), status=status.HTTP_200_OK)
else:
return Response({}, status=status.HTTP_404_NOT_FOUND)
return Response({}, status=status.HTTP_204_NO_CONTENT)
def post(self, request):
data: dict = request.data