Commits

Joe Boutros committed 7d5051c

added expects_localtime to the compact_date template filter in the case of Django > 1.4.

Comments (0)

Files changed (1)

postman/templatetags/postman_tags.py

         arg = unicode(arg)
     return _('<me>') if value == arg else value
 
-@register.filter
+import django
+if django.VERSION >= (1, 4):
+    date_filter_params = {'expects_localtime':True}
+else:
+    date_filter_params = {}
+
+@register.filter(**date_filter_params)
 def compact_date(value, arg):
     """
     Output a date as short as possible.