From 2defb41ff92635b3bb795277bb7deb4a13a887ce Mon Sep 17 00:00:00 2001 From: Jakob Dieterle <jakob.dieterle@stud.uni-goettingen.de> Date: Thu, 29 Jul 2021 13:00:34 +0200 Subject: [PATCH] fixing for tests --- core/views/common_views.py | 3 --- 1 file changed, 3 deletions(-) diff --git a/core/views/common_views.py b/core/views/common_views.py index 6a0dd846..26d28d4f 100644 --- a/core/views/common_views.py +++ b/core/views/common_views.py @@ -86,7 +86,6 @@ class StudentReviewerApiViewSet(viewsets.ReadOnlyModelViewSet): user__exercise_groups__in=self.request.user.exercise_groups.all() ) - else: return [] @@ -353,10 +352,8 @@ class UserAccountViewSet(viewsets.ReadOnlyModelViewSet): if req_user.is_student() or req_user.is_tutor(): return Response(status.HTTP_403_FORBIDDEN) user = self.get_object() - user_groups = [GroupSerializer(group) for group in user.exercise_groups.all()] return Response(user.exercise_groups, status=status.HTTP_200_OK) - @action(detail=False) def me(self, request): serializer = self.get_serializer(request.user) -- GitLab