From b14ad655c0c54d1630609fe7018895050172874c Mon Sep 17 00:00:00 2001 From: Josue Kouka Date: Wed, 17 Feb 2016 17:03:34 +0100 Subject: [PATCH] remove authentication classes from APIView (#9812) --- src/authentic2/api_views.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/authentic2/api_views.py b/src/authentic2/api_views.py index c41472d..cf7e817 100644 --- a/src/authentic2/api_views.py +++ b/src/authentic2/api_views.py @@ -326,7 +326,6 @@ router = SimpleRouter() router.register(r'users', UsersAPI, base_name='a2-api-users') class RolesAPI(APIView): - authentication_class = (authentication.BasicAuthentication) permission_classes = (permissions.IsAuthenticated,) def initial(self, request, *args, **kwargs): @@ -339,7 +338,7 @@ class RolesAPI(APIView): perm = 'a2_rbac.change_role' authorized = request.user.has_perm(perm, obj=self.role) if not authorized: - raise PermissionDenied(u'User not allowed to change role') + raise PermissionDenied(u'User not allowed to change role') def post(self, request, *args, **kwargs): self.role.members.add(self.member) -- 2.7.0