Commit ad4f706d authored by Julien Rabier's avatar Julien Rabier

don't send reminders for deleted/hidden votes

parent 14b919c0
......@@ -13,7 +13,7 @@ import sqlite3
conn = sqlite3.connect(DATABASE)
c = conn.cursor()
for vote in c.execute('select id, id_group, date_end, title from votes where is_open=1 and is_terminated=0').fetchall():
for vote in c.execute('select id, id_group, date_end, title from votes where is_hidden=0 and is_open=1 and is_terminated=0').fetchall():
date_end_vote = datetime.strptime(vote[2], "%Y-%m-%d")
date_today = datetime.today()
date_begin_reminder = date_end_vote + timedelta(days=-3)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment