Skip to content

Commit

Permalink
Merge branch 'production' of https://github.com/zakarm/ft_transcendence
Browse files Browse the repository at this point in the history
… into wip/chatfolio
  • Loading branch information
Nouakchi committed May 1, 2024
2 parents 13bc611 + 9805d69 commit 7e562eb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/back-end/dashboards/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,9 @@ class ProfileIdView(APIView):
authentication_classes = [JWTAuthentication]
permission_classes = [IsAuthenticated]

def get(self, request, id):
def get(self, request, username):
try:
user = User.objects.get(id=id)
user = User.objects.get(username=username)
serializer_data = ProfileSerializer(instance=user)
return Response(serializer_data.data)
except User.objects.model.DoesNotExist:
Expand Down

0 comments on commit 7e562eb

Please sign in to comment.