diff --git a/zerver/lib/export.py b/zerver/lib/export.py index edfd387b46..497bf77e92 100644 --- a/zerver/lib/export.py +++ b/zerver/lib/export.py @@ -6,7 +6,7 @@ from boto.s3.connection import S3Connection from django.conf import settings from django.db import connection from django.forms.models import model_to_dict -from django.utils import timezone +from django.utils.timezone import make_aware as timezone_make_aware from django.utils.timezone import utc as timezone_utc from django.utils.timezone import is_naive as timezone_is_naive from django.db.models.query import QuerySet @@ -181,7 +181,7 @@ def floatify_datetime_fields(data, table): continue if timezone_is_naive(orig_dt): logging.warning("Naive datetime:", item) - dt = timezone.make_aware(orig_dt) + dt = timezone_make_aware(orig_dt) else: dt = orig_dt utc_naive = dt.replace(tzinfo=None) - dt.utcoffset()