When saving options for this plugin, i get:
warning: array_filter() [function.array-filter]: The first argument should be an array in /drupal/sites/views3dev/modules/views/modules/user/views_plugin_argument_validate_user.inc on line 56.
This is produced by this function with a extraneous $options parameter:
function options_submit(&$form, &$form_state, &$options) {
// filter trash out of the options so we don't store giant unnecessary arrays
$options['roles'] = array_filter($options['roles']);
}
However if this function is removed, "Restrict user based on role" and "Roles" are not saved.
Also, the process_dependency is broken and roles are displayed even if "Restrict user based on role" is unchecked.
| Comment | File | Size | Author |
|---|---|---|---|
| #3 | 646236-fix-user-validate-plugin.patch | 2.95 KB | merlinofchaos |
| #2 | views-646236.patch | 1.82 KB | dagmar |
Comments
Comment #1
dagmartagging
Comment #2
dagmarThis patch fix the dependency bug, but options are still not saved. Also in options_submit(&$form, &$form_state, &$options) options has this structure
And this doesn't make sense for.
Comment #3
merlinofchaos commentedReworked so that it's all correct. The unset array was, I think, a side effect of the wrong plugin's data being sent to the options_submit. Committed patch attached.
Comment #4
merlinofchaos commentedLosing tag.
Comment #5
dawehnerand fixed