summaryrefslogtreecommitdiff
path: root/django/db/backends/postgresql/utils.py
diff options
context:
space:
mode:
Diffstat (limited to 'django/db/backends/postgresql/utils.py')
-rw-r--r--django/db/backends/postgresql/utils.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/django/db/backends/postgresql/utils.py b/django/db/backends/postgresql/utils.py
new file mode 100644
index 0000000000..2c03ab36cd
--- /dev/null
+++ b/django/db/backends/postgresql/utils.py
@@ -0,0 +1,7 @@
+from django.utils.timezone import utc
+
+
+def utc_tzinfo_factory(offset):
+ if offset != 0:
+ raise AssertionError("database connection isn't set to UTC")
+ return utc