Sorry can't roll a patch right now.

function views_page() {
  $args = func_get_args();
  $name = array_shift($args);
  $display_id = array_shift($args);
...

Changed to

function views_page($name, $display_id) {
  $args = func_get_args();
  // Remove $name and $display_id from the arguments.
  unset($args[0], $args[1]);
...

$args will now be an array without the first two indexes; array(2 => 'foo', 3 => 'bar') instead of array(0 => 'foo', 1 => 'bar')

Not sure what all consequenses are but date views pager stopped working at least.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

merlinofchaos’s picture

You can use array_values() to reset the indexes, but unset() is probably just wrong and array_shift should be used to remove the arguments from the array.

dawehner’s picture

Status: Active » Fixed

Just committed a fix. I don't really get why date module relies on that behavior but hey there should be some problems left :)

tim.plunkett’s picture

Status: Fixed » Needs review
FileSize
533 bytes

So that fix is broken (http://qa.drupal.org/pifr/test/27332).

This is why we have a testbot! :)

I'm also not sure why this was broken, I might look into it more, I'd much rather just follow the intention of #1414068: Fix PHP warnings when a View path 404/3's.

tim.plunkett’s picture

FileSize
492 bytes

Er, there was also this one.

merlinofchaos’s picture

Status: Needs review » Fixed

Committed #4.

Status: Fixed » Closed (fixed)

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