File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -90,9 +90,10 @@ Startup up a new project like so...
90
90
Now edit the ` example/urls.py ` module in your project:
91
91
92
92
``` python
93
- from django.urls import path, include
94
93
from django.contrib.auth.models import User
95
- from rest_framework import serializers, viewsets, routers
94
+ from django.urls import include, path
95
+ from rest_framework import routers, serializers, viewsets
96
+
96
97
97
98
# Serializers define the API representation.
98
99
class UserSerializer (serializers .HyperlinkedModelSerializer ):
@@ -111,7 +112,6 @@ class UserViewSet(viewsets.ModelViewSet):
111
112
router = routers.DefaultRouter()
112
113
router.register(r ' users' , UserViewSet)
113
114
114
-
115
115
# Wire up our API using automatic URL routing.
116
116
# Additionally, we include login URLs for the browsable API.
117
117
urlpatterns = [
You can’t perform that action at this time.
0 commit comments