]> git.openstreetmap.org Git - osqa.git/blobdiff - forum/models/tag.py
OSQA-748, smart unicode filtration for the username in the accept rate singular title
[osqa.git] / forum / models / tag.py
index 912697b5cf63131b36eb23eabb8e8e541a702280..067488b2f97ca6bc77c6a6f9cca25c281ceb6070 100644 (file)
@@ -2,7 +2,7 @@ import datetime
 from base import *
 
 from django.utils.translation import ugettext as _
-from django.utils.encoding import smart_unicode
+from django.utils.encoding import smart_unicode, force_unicode
 
 from forum import modules
 
@@ -27,7 +27,7 @@ class Tag(BaseModel):
         app_label = 'forum'
 
     def __unicode__(self):
-        return unicode(self.name)
+        return force_unicode(self.name)
 
     def add_to_usage_count(self, value):
         if self.used_count + value < 0: