aboutsummaryrefslogtreecommitdiffstats
path: root/docs/api-guide/viewsets.md
diff options
context:
space:
mode:
authorTom Christie2013-04-26 14:59:21 +0100
committerTom Christie2013-04-26 14:59:21 +0100
commit8fa79a7fd38dda015afa658084361c6da2856e46 (patch)
treeef8080a9d24b488402429c0bae101e3f395f1f8b /docs/api-guide/viewsets.md
parente301e2d974649a932ab9a7ca32199c068fa30495 (diff)
downloaddjango-rest-framework-8fa79a7fd38dda015afa658084361c6da2856e46.tar.bz2
Deal with List/Instance suffixes for viewsets
Diffstat (limited to 'docs/api-guide/viewsets.md')
-rw-r--r--docs/api-guide/viewsets.md2
1 files changed, 1 insertions, 1 deletions
diff --git a/docs/api-guide/viewsets.md b/docs/api-guide/viewsets.md
index 36a4dbd5..8af35bb8 100644
--- a/docs/api-guide/viewsets.md
+++ b/docs/api-guide/viewsets.md
@@ -42,7 +42,7 @@ If we need to, we can bind this viewset into two seperate views, like so:
Typically we wouldn't do this, but would instead register the viewset with a router, and allow the urlconf to be automatically generated.
router = DefaultRouter()
- router.register(r'users', UserViewSet, 'user')
+ router.register(r'users', UserViewSet, name='user')
urlpatterns = router.urls
Rather than writing your own viewsets, you'll often want to use the existing base classes that provide a default set of behavior. For example: