We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent eb0e715 commit fce63fbCopy full SHA for fce63fb
1 file changed
code_comments/comment.py
@@ -1,8 +1,9 @@
1
import re
2
+import locale
3
4
import trac.wiki.formatter
5
from trac.mimeview.api import Context
-from time import gmtime, strftime
6
+from time import strftime, localtime
7
from code_comments import db
8
from trac.util import Markup
9
@@ -113,7 +114,8 @@ def path_link_tag(self):
113
114
return Markup('<a href="%s">%s</a>' % (self.href(), self.link_text()))
115
116
def formatted_date(self):
- return strftime('%d %b %Y, %H:%M', gmtime(self.time))
117
+ encoding = locale.getlocale()[1] if locale.getlocale()[1] else 'utf-8'
118
+ return strftime('%d %b %Y, %H:%M', localtime(self.time)).decode(encoding)
119
120
def get_ticket_relations(self):
121
relations = set()
0 commit comments