Fix missing import in example code

This commit is contained in:
Phil Ratcliffe 2018-12-28 16:10:08 +00:00
parent 97a47958c0
commit 1a9548db4f

View File

@ -104,7 +104,7 @@ __Note:__ when you set new permission classes through class attribute or decorat
Provided they inherit from `rest_framework.permissions.BasePermission`, permissions can be composed using standard Python bitwise operators. For example, `IsAuthenticatedOrReadOnly` could be written: Provided they inherit from `rest_framework.permissions.BasePermission`, permissions can be composed using standard Python bitwise operators. For example, `IsAuthenticatedOrReadOnly` could be written:
from rest_framework.permissions import BasePermission, IsAuthenticated from rest_framework.permissions import BasePermission, IsAuthenticated, SAFE_METHODS
from rest_framework.response import Response from rest_framework.response import Response
from rest_framework.views import APIView from rest_framework.views import APIView