The form for adding/editing a poll triggers a JavaScript error for users that do not have the administer polls permission. This causes the Poll Settings block to be collapsed without means to open it.
I have traced it to advpoll-form.js, line 56:

if ($("input.settings-writeins").attr("checked")) {

Apparently, when the user does not have the administer polls permission, settings-writeins is not there, $("input.settings-writeins") returns an empty list and the $("input.settings-writeins").attr() fails.
A possible fix is to change the line to this:

if ($("input.settings-writeins").length && $("input.settings-writeins").attr("checked")) {

CommentFileSizeAuthor
#1 advpoll_writein_js.patch1.04 KBanders.fajerson

Comments

anders.fajerson’s picture

Status: Active » Needs review
StatusFileSize
new1.04 KB

Thanks for the report. Here is a patch (which does the check a bit earlier).

ChrisKennedy’s picture

Status: Needs review » Closed (duplicate)

Wow, this bug was solved nearly a year earlier than my recent commit. Sorry!

http://drupal.org/node/189418

anders.fajerson’s picture

I should have told you (or better yet, committed it)...