NOT a voter..

This commit is contained in:
Ville Rantanen
2018-12-13 22:06:23 +02:00
parent a1cf9ddc64
commit 811554c78d

View File

@@ -65,7 +65,7 @@ def vote(key, token = None):
if is_expired(form):
return render_template('blank.html', message = "Voting has closed")
if is_closed_vote(form):
if is_voter(key, token):
if not is_voter(key, token):
return render_template('blank.html', message = "Token invalid")
if has_voted(key, token):
return render_template('blank.html', message = "Token already used")