We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5436d63 commit c1409a4Copy full SHA for c1409a4
easyaudit/utils.py
@@ -1,5 +1,6 @@
1
from __future__ import unicode_literals
2
3
+import datetime as dt
4
from uuid import UUID
5
6
from django.conf import settings
@@ -25,7 +26,7 @@ def get_field_value(obj, field):
25
26
try:
27
value = field.to_python(getattr(obj, field.name, None))
28
if value is not None and settings.USE_TZ and not timezone.is_naive(value):
- value = timezone.make_naive(value, timezone=timezone.utc)
29
+ value = timezone.make_naive(value, timezone=dt.timezone.utc)
30
except ObjectDoesNotExist:
31
value = field.default if field.default is not NOT_PROVIDED else None
32
else:
0 commit comments