Skip to content

Commit

Permalink
Typos
Browse files Browse the repository at this point in the history
  • Loading branch information
Hugo Geoffroy committed Apr 24, 2014
1 parent 73e3dd4 commit 22e69d9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions django_crucrudile/models/mixins.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ def _get_url(obj, *args, **kwargs):
"""Private function, patched as ``get_*_url`` to the model mixin.
"""
if instance_view or view.instance_view:
if instance_view or view_class.instance_view:
kwargs['args'].append(obj.id)
return reverse(
obj.get_url_name(view_class, prefix=True),
Expand All @@ -103,7 +103,7 @@ def _get_url(obj, *args, **kwargs):
_get_url.__doc__ = "Get %s URL" % view_class.get_action_name()
# we make _get_url a class method only at this point to be able
# to change __doc__
if not instance_view:
if not (instance_view or view_class.instance_view):
_get_url = classmethod(_get_url)

setattr(ModelMixin,
Expand Down

0 comments on commit 22e69d9

Please sign in to comment.