summaryrefslogtreecommitdiff
path: root/modules/quotes.py
diff options
context:
space:
mode:
authorJon Bergli Heier <snakebite@jvnv.net>2010-05-03 14:46:11 +0200
committerJon Bergli Heier <snakebite@jvnv.net>2010-05-03 14:46:11 +0200
commitd2ce9f3eaf4bbd0ce97f8158ee676a56c8e00a1a (patch)
tree2b4176a6b547922d14152b3a6d41262a7d13cc78 /modules/quotes.py
parent8b5ad903dbce73faecd9682b3d1d14f876627853 (diff)
quotes: Fixed timestamp when adding quotes.
Diffstat (limited to 'modules/quotes.py')
-rw-r--r--modules/quotes.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/quotes.py b/modules/quotes.py
index 3592451..13c8a6d 100644
--- a/modules/quotes.py
+++ b/modules/quotes.py
@@ -27,7 +27,7 @@ class Quotes:
def add(self, nick, quote):
cur = self.db.cursor()
- cur.execute('insert into quotes (nick, date, quote) values (%s, %s, %s)', (nick, int(time.time()), quote))
+ cur.execute('insert into quotes (nick, date, quote) values (%s, datetime("now"), %s)', (nick, quote))
cur.execute('select currval(\'quotes_id_seq\')')
lastrowid = cur.fetchone()[0]
cur.close()