Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Teeny weeny optimization to RegexURLPattern.resolve()

git-svn-id: http://code.djangoproject.com/svn/django/trunk@4587 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit 6871a455e2f2362806b7424f1afb44b46e551bb4 1 parent 2589562
Adrian Holovaty authored

Showing 1 changed file with 2 additions and 2 deletions. Show diff stats Hide diff stats

  1. 4  django/core/urlresolvers.py
4  django/core/urlresolvers.py
@@ -16,7 +16,7 @@ class Resolver404(Http404):
16 16
 
17 17
 class NoReverseMatch(Exception):
18 18
     # Don't make this raise an error when used in a template.
19  
-    silent_variable_failure = True  
  19
+    silent_variable_failure = True
20 20
 
21 21
 def get_mod_func(callback):
22 22
     # Converts 'django.views.news.stories.story_detail' to
@@ -110,7 +110,7 @@ def resolve(self, path):
110 110
             kwargs = match.groupdict()
111 111
             if kwargs:
112 112
                 args = ()
113  
-            if not kwargs:
  113
+            else:
114 114
                 args = match.groups()
115 115
             # In both cases, pass any extra_kwargs as **kwargs.
116 116
             kwargs.update(self.default_args)

0 notes on commit 6871a45

Please sign in to comment.
Something went wrong with that request. Please try again.