IsAdmin permissions changed to IsAdminUser

Documentation change to keep up with the code permission changes.
This commit is contained in:
Jeremy Langley 2021-10-28 01:49:21 -07:00
parent 00cd4ef864
commit 7ace42a5ec
2 changed files with 2 additions and 2 deletions

View File

@ -125,7 +125,7 @@ You may inspect these attributes to adjust behaviour based on the current action
if self.action == 'list':
permission_classes = [IsAuthenticated]
else:
permission_classes = [IsAdmin]
permission_classes = [IsAdminUser]
return [permission() for permission in permission_classes]
## Marking extra actions for routing

View File

@ -110,7 +110,7 @@ You can now compose permission classes using the and/or operators, `&` and `|`.
For example...
```python
permission_classes = [IsAuthenticated & (ReadOnly | IsAdmin)]
permission_classes = [IsAuthenticated & (ReadOnly | IsAdminUser)]
```
If you're using custom permission classes then make sure that you are subclassing