Commit 1437519d authored by Simcha van Collem's avatar Simcha van Collem
Browse files

The response is now json

parent 9b0f9b66
......@@ -47,7 +47,7 @@ class ObtainThaliaAuthToken(ObtainAuthToken):
)
if not serializer.is_valid():
return HttpResponse("Unauthorized", status=401)
return Response({"error": "Unauthorized"}, status=401)
user = serializer.validated_data["user"]
token, created = Token.objects.get_or_create(user=user)
......
Supports Markdown
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