[damned-lies] Init datetime with timezone in get_lang_files
- From: Claude Paroz <claudep src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [damned-lies] Init datetime with timezone in get_lang_files
- Date: Tue, 7 Dec 2021 17:09:16 +0000 (UTC)
commit 09c3573a19415cc319df8d1fdc0028b3ee5ab7f8
Author: Claude Paroz <claude 2xlibre net>
Date: Tue Dec 7 18:08:39 2021 +0100
Init datetime with timezone in get_lang_files
stats/models.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/stats/models.py b/stats/models.py
index 102d3ff3..7ecc9efa 100644
--- a/stats/models.py
+++ b/stats/models.py
@@ -1280,7 +1280,7 @@ class Release(models.Model):
po_stats = {f"{st.branch_id}-{st.domain_id}": st
for st in Statistics.objects.filter(language=lang, branch__releases=self,
domain__dtype=dtype)}
lang_files = []
- last_modif_date = datetime(1970, 1, 1)
+ last_modif_date = datetime(1970, 1, 1, tzinfo=timezone.utc)
# Create list of files
for stat in pot_stats:
if stat.full_po.updated > last_modif_date:
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]