summaryrefslogtreecommitdiff
path: root/django/utils/timezone.py
diff options
context:
space:
mode:
authorCarlton Gibson <carlton.gibson@noumenal.es>2022-03-23 12:15:36 +0100
committerMariusz Felisiak <felisiak.mariusz@gmail.com>2022-03-24 06:29:50 +0100
commitbb61f0186d5c490caa44f3e3672d81e14414d33c (patch)
tree71e682d415e4640fd1e950af0e4921b2af57ea60 /django/utils/timezone.py
parent1cf60ce6017d904024ee132f7edae0b4b821a954 (diff)
Refs #32365 -- Removed internal uses of utils.timezone.utc alias.
Remaining test case ensures that uses of the alias are mapped canonically by the migration writer.
Diffstat (limited to 'django/utils/timezone.py')
-rw-r--r--django/utils/timezone.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/django/utils/timezone.py b/django/utils/timezone.py
index 71b160448e..33c0440095 100644
--- a/django/utils/timezone.py
+++ b/django/utils/timezone.py
@@ -224,7 +224,7 @@ def now():
"""
Return an aware or naive datetime.datetime, depending on settings.USE_TZ.
"""
- return datetime.now(tz=utc if settings.USE_TZ else None)
+ return datetime.now(tz=timezone.utc if settings.USE_TZ else None)
# By design, these four functions don't perform any checks on their arguments.