mirror of
https://github.com/encode/django-rest-framework.git
synced 2025-07-27 08:29:59 +03:00
Merge 302f58d8f6
into 6c1fcc855a
This commit is contained in:
commit
472b14f624
|
@ -120,7 +120,7 @@ class DjangoModelPermissions(BasePermission):
|
|||
|
||||
perms = self.get_required_permissions(request.method, model_cls)
|
||||
|
||||
if (request.user and
|
||||
if not perms or (request.user and
|
||||
request.user.is_authenticated() and
|
||||
request.user.has_perms(perms)):
|
||||
return True
|
||||
|
|
Loading…
Reference in New Issue
Block a user