panopoly_admin moves 'field_featured_status' into the node 'options' (ie. Publishing options) - which is great! Except when the given user doesn't have permission to access the node 'options' but DOES have permission to access 'field_featured_status'.

Comments

dsnopek’s picture

Status: Active » Fixed

Committed in 1beb1e2.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.

pfaocle’s picture

Status: Closed (fixed) » Needs work

This commit may have introduced an issue - most of the statements in this _form_alter are NOT wrapped in a check to see if we're on the node form. This is not an issue in most cases as !empty() is used (e.g. on lines 234, 238, 248). However, this change means that $form['options'] is accessed without checking whether it exists, which throws a PHP notice.

It also seems a bit excessive to be making these checks on forms that aren't the node edit form - shouldn't a lot of this be wrapped in the if (isset($form['#entity_type']) && $form['#entity_type'] == 'node') { clause on ln157?

dsnopek’s picture

Status: Needs work » Closed (fixed)

@pfaocle: Can you open a new issue for that? Even if the problem was introduced by this issue, we really only re-open committed issues if the original issue wasn't solved at all or if we're going to revert them. You can (and should!) reference this issue in the new issue.