Commit 9ac471cd authored by Feri's avatar Feri
Browse files

/me 401

parent faaae386
Pipeline #3261 passed with stage
in 1 minute and 49 seconds
......@@ -47,14 +47,12 @@ class ProfileViewSet(
@action(detail=False, permission_classes=[])
def me(self, request):
serializer = serializers.OwnProfileSerializer(
request.user.profile, many=False
return Response(
except AttributeError:
if not request.user.is_authenticated:
return Response(status=401)
serializer = serializers.OwnProfileSerializer(request.user.profile, many=False)
return Response(
class AvatarViewSet(
RelativeURLFieldMixin, generics.RetrieveUpdateAPIView, viewsets.GenericViewSet
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