bug simple poll
Reported by neryo | April 24th, 2012 @ 03:06 PM | in 2.0.7 (closed)
Hi,
there's a bug simple poll module.. if the simple poll is "open
voting" when a not logged user tries to vote with at least one vote
done, it's like the user has already voted even if has another ip
address. I've seen in the database that the column user_id in the
exponent_poll_timeblock table is always 0 and ip_hash is empty.. so
it seems that $user is not an object or/and $user->id is 0.
i've fixed it in simplepollmodule/action/vote.php:
replace
if ($user)
with
if (is_object($user) && $user->id > 0)
there are 2 rows to replace.
i think it's always better to check objects and arrays properly before using them
bye
Comments and changes to this ticket
-
expNinja April 24th, 2012 @ 03:24 PM
- State changed from new to resolved
- Milestone set to 2.0.7
- Milestone order changed from 99 to 0
(from [21a00d5cf812a6dfb6fb2841f8f2611fea0e2ddc]) Should fix an issue with simple poll voting by anonmymous users [#588 state:resolved milestone:2.0.7] https://github.com/exponentcms/exponent-cms/commit/21a00d5cf812a6df...
Please Sign in or create a free account to add a new ticket.
With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป
Bug Tracker for Exponent CMS