From a210936dcfb3a8f20e4cc0d8195fa8c130c9a369 Mon Sep 17 00:00:00 2001 From: Thomas Waldmann Date: Sun, 27 Oct 2013 07:29:58 +0100 Subject: [PATCH] use now() from django.utils.timezone - it is utc and not naive --- nsupdate/main/models.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/nsupdate/main/models.py b/nsupdate/main/models.py index 138570c..1de22de 100644 --- a/nsupdate/main/models.py +++ b/nsupdate/main/models.py @@ -1,5 +1,5 @@ import re -from datetime import datetime +from django.utils.timezone import now import dns.resolver @@ -118,7 +118,7 @@ class Host(models.Model): return 'error' def poke(self): - self.last_api_update = datetime.now() + self.last_api_update = now() self.save() def generate_secret(self):