Commits

Andy Mikhailenko  committed 2c446db

Bugfix.

  • Participants
  • Parent commits c930db1

Comments (0)

Files changed (3)

File navigation/__init__.py

 __author__  = 'Andy Mikhailenko'
 __license__ = 'GNU Lesser General Public License (GPL), Version 3'
 __url__     = 'http://bitbucket.org/neithere/django-navigation/'
-__version__ = '0.6.3'
+__version__ = '0.6.4'

File navigation/helpers.py

         by a :term:`crumb resolver`.
 
     """
-    def __init__(self, url, title, is_current=False, is_dummy=False):
+    def __init__(self, url, title, is_current=False, is_active=False,
+                 is_dummy=False):
         self.url        = url
         self.title      = title
         self.is_current = is_current

File navigation/resolvers.py

     for resolver in RESOLVERS:
         crumb = resolver(request, url)
         if crumb is not None:
-            crumb.is_current = bool(url == request.path)
-            crumb.is_active = bool(url.startswith(request.path))
+            crumb.is_current = request.path == url
+            crumb.is_active  = request.path.startswith(url)
             return crumb
 
     # TODO return None instead of a fake breadcrumb object