mirror of
https://github.com/django/django.git
synced 2025-10-24 06:06:09 +00:00
Fixed #21927 -- Made application and instance namespaces more distinct.
Made URL application namespaces be set in the included URLconf and instance namespaces in the call to include(). Deprecated other ways to set application and instance namespaces.
This commit is contained in:
committed by
Tim Graham
parent
39937de7e6
commit
1e82094f1b
@@ -3,12 +3,12 @@ from django.contrib import admin
|
||||
|
||||
from . import views
|
||||
|
||||
ns_patterns = [
|
||||
ns_patterns = ([
|
||||
url(r'^xview/func/$', views.xview_dec(views.xview), name='func'),
|
||||
]
|
||||
], 'test')
|
||||
|
||||
urlpatterns = [
|
||||
url(r'^admin/', include(admin.site.urls)),
|
||||
url(r'^admin/', admin.site.urls),
|
||||
url(r'^admindocs/', include('django.contrib.admindocs.urls')),
|
||||
url(r'^', include(ns_patterns, namespace='test')),
|
||||
url(r'^xview/func/$', views.xview_dec(views.xview)),
|
||||
|
||||
Reference in New Issue
Block a user