Commit 20710004 authored by Julien Rabier's avatar Julien Rabier

[fix] make private votes visible as expected

parent 863722fd
......@@ -441,7 +441,7 @@ def can_see_vote(idvote, iduser=-1):
return False
if not vote['is_public']:
user = query_db('select * from users where id=?', [iduser], one=True)
if query_db('select * from user_group where id_user = ? and id_group = ?', [iduser, vote['id']], one=True) is None:
if query_db('select * from user_group where id_user = ? and id_group = ?', [iduser, vote['id_group']], one=True) is None:
return False
return True
......
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