diff options
| author | Tim Graham <timograham@gmail.com> | 2014-02-16 19:28:48 -0500 |
|---|---|---|
| committer | Tim Graham <timograham@gmail.com> | 2014-02-28 07:18:45 -0500 |
| commit | 72b080c2c8a5ab7930b13688b2865ebc5b636687 (patch) | |
| tree | 30780a69b1e895dff4bb7e19dc378b0a25e746b0 /django | |
| parent | c23b3717be71e4b2e5a32f156ef0a7b4703d012d (diff) | |
Removed Django 1.5 upgrade hints for {% url %} tag.
Refs #19280 and Refs #19392.
Diffstat (limited to 'django')
| -rw-r--r-- | django/template/defaulttags.py | 11 |
1 files changed, 1 insertions, 10 deletions
diff --git a/django/template/defaulttags.py b/django/template/defaulttags.py index da29c7eaba..0f24d23a02 100644 --- a/django/template/defaulttags.py +++ b/django/template/defaulttags.py @@ -434,10 +434,6 @@ class URLNode(Node): view_name = self.view_name.resolve(context) - if not view_name: - raise NoReverseMatch("'url' requires a non-empty first argument. " - "The syntax changed in Django 1.5, see the docs.") - # Try to look up the URL twice: once given the view name, and again # relative to what we guess is the "main" app. If they both fail, # re-raise the NoReverseMatch unless we're using the @@ -1345,12 +1341,7 @@ def url(parser, token): if len(bits) < 2: raise TemplateSyntaxError("'%s' takes at least one argument" " (path to a view)" % bits[0]) - try: - viewname = parser.compile_filter(bits[1]) - except TemplateSyntaxError as exc: - exc.args = (exc.args[0] + ". " - "The syntax of 'url' changed in Django 1.5, see the docs."), - raise + viewname = parser.compile_filter(bits[1]) args = [] kwargs = {} asvar = None |
