diff options
author | Aurélien Bompard <aurelien@bompard.org> | 2013-05-27 20:52:03 +0200 |
---|---|---|
committer | Aurélien Bompard <aurelien@bompard.org> | 2013-05-27 21:18:29 +0200 |
commit | dad66ad5a2c8a9645e0127e09283082f3c439a28 (patch) | |
tree | a345405f0d4228b246f4b6dce3d00dcda1e06d91 /hyperkitty/views/thread.py | |
parent | 2a84b82a17e6986b3265d958f89d562c241a7a80 (diff) | |
download | hyperkitty-dad66ad5a2c8a9645e0127e09283082f3c439a28.tar.gz hyperkitty-dad66ad5a2c8a9645e0127e09283082f3c439a28.tar.xz hyperkitty-dad66ad5a2c8a9645e0127e09283082f3c439a28.zip |
Rework the display of email datetimes using timezones
Diffstat (limited to 'hyperkitty/views/thread.py')
-rw-r--r-- | hyperkitty/views/thread.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/hyperkitty/views/thread.py b/hyperkitty/views/thread.py index 34fc5d9..03cfd6a 100644 --- a/hyperkitty/views/thread.py +++ b/hyperkitty/views/thread.py @@ -30,6 +30,7 @@ from django.template import RequestContext, loader from django.shortcuts import render from django.core.urlresolvers import reverse from django.core.exceptions import SuspiciousOperation +from django.utils.timezone import utc import robot_detection from hyperkitty.models import Tag, Favorite, LastView @@ -166,7 +167,7 @@ def replies(request, mlist_fqdn, threadid): last_view = request.GET.get("last_view") if last_view: try: - last_view = datetime.datetime.fromtimestamp(int(last_view)) + last_view = datetime.datetime.fromtimestamp(int(last_view), utc) except ValueError: last_view = None context = { |