Fix everyone can vote

Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
Thomas Citharel 2018-03-21 15:28:58 +01:00
parent 4e021c2bc3
commit bfc986a66e

View File

@ -168,7 +168,7 @@ if ($accessGranted) {
try {
$result = $pollService->addVote($poll_id, $name, $choices, $slots_hash);
if ($result) {
if ($poll->editable === Editable::EDITABLE_BY_OWN) {
if (intval($poll->editable) === Editable::EDITABLE_BY_OWN) {
$editedVoteUniqueId = $result->uniqId;
$message = getMessageForOwnVoteEditableVote($sessionService, $smarty, $editedVoteUniqueId, $config['use_smtp'], $poll_id, $name);
} else {