A very specific issue - but I'm writing a module that allows multiple views access plugins to work on the same view - combining them with a logical operator. In the UI for a view the user can choose multiple access plugins and set their options in one form.
To help the UI I call each access plugins' summary_title() method before calling their options_form() method. Now, it appears that the role access plugin calls array_unshift($this->options['role'])
during it's summary_title() method to grab the role selected. However this inadvertently wipes out that option for the rest of the lifetime of that instance of the plugin.
While I realise that it has never caused a problem before - essentially a call to an access plugin's summary_title()
method has never been followed by a call to any other method on the plugin, it is causing a problem for my module. And the solution is so simple.
I've fixed the issue in all branches - I'll add a patch here shortly.
Comments
Comment #1
jamsilver CreditAttribution: jamsilver commentedI know it seems insignificant, but it's quite annoying for http://drupal.org/project/views_access_many and it makes most sense for it to be corrected here.
Comment #2
jamsilver CreditAttribution: jamsilver commentedOops, didn't mean to add tags
Comment #3
jamsilver CreditAttribution: jamsilver commentedSorry! Those weren't rolled correctly. I've confirmed that these ones apply.
Comment #4
jamsilver CreditAttribution: jamsilver commentedprobably a more appropriate starting status..
Comment #5
jamsilver CreditAttribution: jamsilver commentedOK, on reflection - please review my patch =)
Comment #6
dawehnerThey make sense.
Comment #7
dawehnerAnd commited to all three branches.