mirror of
https://github.com/django/django.git
synced 2025-10-25 06:36:07 +00:00
[1.7.x] Fixed #22486 -- Restored the ability to reverse views created using functools.partial.
Regression in8b93b31487. Thanks rcoup for the report. Backport of3c06b2f2a3from master
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
from django.conf.urls import patterns, url, include
|
||||
|
||||
from .views import empty_view, absolute_kwargs_view
|
||||
from .views import empty_view, empty_view_partial, empty_view_wrapped, absolute_kwargs_view
|
||||
|
||||
|
||||
other_patterns = patterns('',
|
||||
@@ -51,6 +51,10 @@ urlpatterns = patterns('',
|
||||
# This is non-reversible, but we shouldn't blow up when parsing it.
|
||||
url(r'^(?:foo|bar)(\w+)/$', empty_view, name="disjunction"),
|
||||
|
||||
# Partials should be fine.
|
||||
url(r'^partial/', empty_view_partial, name="partial"),
|
||||
url(r'^partial_wrapped/', empty_view_wrapped, name="partial_wrapped"),
|
||||
|
||||
# Regression views for #9038. See tests for more details
|
||||
url(r'arg_view/$', 'kwargs_view'),
|
||||
url(r'arg_view/(?P<arg1>\d+)/$', 'kwargs_view'),
|
||||
|
||||
Reference in New Issue
Block a user