aboutsummaryrefslogtreecommitdiff
path: root/tagging
diff options
context:
space:
mode:
Diffstat (limited to 'tagging')
-rw-r--r--tagging/__init__.py2
-rw-r--r--tagging/templatetags/tagging_tags.py8
2 files changed, 5 insertions, 5 deletions
diff --git a/tagging/__init__.py b/tagging/__init__.py
index 735691d..8e300fd 100644
--- a/tagging/__init__.py
+++ b/tagging/__init__.py
@@ -1,7 +1,7 @@
"""
Django-tagging
"""
-__version__ = '0.4'
+__version__ = '0.4.1'
__license__ = 'BSD License'
__author__ = 'Jonathan Buchanan'
diff --git a/tagging/templatetags/tagging_tags.py b/tagging/templatetags/tagging_tags.py
index bd38b30..4e179fb 100644
--- a/tagging/templatetags/tagging_tags.py
+++ b/tagging/templatetags/tagging_tags.py
@@ -5,7 +5,7 @@ from django.template import Node
from django.template import Library
from django.template import Variable
from django.template import TemplateSyntaxError
-from django.db.models import get_model
+from django.apps.registry import apps
from django.utils.translation import ugettext as _
from tagging.utils import LINEAR
@@ -24,7 +24,7 @@ class TagsForModelNode(Node):
self.counts = counts
def render(self, context):
- model = get_model(*self.model.split('.'))
+ model = apps.get_model(*self.model.split('.'))
if model is None:
raise TemplateSyntaxError(
_('tags_for_model tag was given an invalid model: %s') %
@@ -41,7 +41,7 @@ class TagCloudForModelNode(Node):
self.kwargs = kwargs
def render(self, context):
- model = get_model(*self.model.split('.'))
+ model = apps.get_model(*self.model.split('.'))
if model is None:
raise TemplateSyntaxError(
_('tag_cloud_for_model tag was given an invalid model: %s') %
@@ -69,7 +69,7 @@ class TaggedObjectsNode(Node):
self.model = model
def render(self, context):
- model = get_model(*self.model.split('.'))
+ model = apps.get_model(*self.model.split('.'))
if model is None:
raise TemplateSyntaxError(
_('tagged_objects tag was given an invalid model: %s') %