Update Tutorial - Relationships & Hyperlinked APIs (#7950)

unnecessary import, because it is already added in the previous section
This commit is contained in:
juliangeissler 2021-08-08 15:45:00 +02:00 committed by GitHub
parent e95e91ccf2
commit cdd53c7de9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -31,7 +31,6 @@ The other thing we need to consider when creating the code highlight view is tha
Instead of using a concrete generic view, we'll use the base class for representing instances, and create our own `.get()` method. In your `snippets/views.py` add:
from rest_framework import renderers
from rest_framework.response import Response
class SnippetHighlight(generics.GenericAPIView):
queryset = Snippet.objects.all()