Ticket #8554: cast_to_unicode.diff
File cast_to_unicode.diff, 780 bytes (added by , 16 years ago) |
---|
-
django/contrib/comments/templatetags/comments.py
3 3 from django.conf import settings 4 4 from django.contrib.contenttypes.models import ContentType 5 5 from django.contrib import comments 6 from django.utils.encoding import smart_unicode 6 7 7 8 register = template.Library() 8 9 … … 77 78 78 79 qs = self.comment_model.objects.filter( 79 80 content_type = ctype, 80 object_pk = object_pk,81 object_pk = smart_unicode(object_pk), 81 82 site__pk = settings.SITE_ID, 82 83 is_public = True, 83 84 )