diff options
| author | Ethan Fremen | 2013-06-10 10:29:25 -0700 |
|---|---|---|
| committer | Ethan Fremen | 2013-06-10 10:29:25 -0700 |
| commit | 0e75bcd2592caa8862e0b0166a6b851a3eada749 (patch) | |
| tree | 4be625563775f1cab06219d3a7a5a62c0ff74bfd /rest_framework/routers.py | |
| parent | de00ec95c3007dd90b5b01f7486b430699ea63c1 (diff) | |
| parent | 5d0aeef69ecec70242513195c19edcb622e14371 (diff) | |
| download | django-rest-framework-0e75bcd2592caa8862e0b0166a6b851a3eada749.tar.bz2 | |
Merge remote-tracking branch 'upstream/master' into writable-nested-modelserializer
Diffstat (limited to 'rest_framework/routers.py')
| -rw-r--r-- | rest_framework/routers.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/rest_framework/routers.py b/rest_framework/routers.py index 9764e569..f70c2cdb 100644 --- a/rest_framework/routers.py +++ b/rest_framework/routers.py @@ -215,6 +215,7 @@ class DefaultRouter(SimpleRouter): """ include_root_view = True include_format_suffixes = True + root_view_name = 'api-root' def get_api_root_view(self): """ @@ -244,7 +245,7 @@ class DefaultRouter(SimpleRouter): urls = [] if self.include_root_view: - root_url = url(r'^$', self.get_api_root_view(), name='api-root') + root_url = url(r'^$', self.get_api_root_view(), name=self.root_view_name) urls.append(root_url) default_urls = super(DefaultRouter, self).get_urls() |
