Return 200 if resource already exists (no scrobble created)

This commit is contained in:
2023-12-01 00:17:10 +01:00
parent e6f78f4b1d
commit 91ed364747

View File

@ -374,7 +374,7 @@ def gps_webhook(request):
scrobble = gpslogger_scrobble_location(data_dict, request.user.id)
if not scrobble:
return Response({}, status=status.HTTP_400_BAD_REQUEST)
return Response({}, status=status.HTTP_200_OK)
return Response({"scrobble_id": scrobble.id}, status=status.HTTP_200_OK)