6.12 has a function in modules/system/system.admin.inc with the following parameters:

function system_clear_cache_submit(&$form_state, $form) {
  drupal_flush_all_caches();
  drupal_set_message(t('Caches cleared.'));
}

6.13 released today, 7/1/09 has the parameters reversed in a new version:

function system_clear_cache_submit($form, &$form_state) {
  drupal_flush_all_caches();
  drupal_set_message(t('Caches cleared.'));
}

Just a blip? Causes problem in Admin menu. Only called from system_performance_settings in same file. I can't see why the order was changed...

Comments

databoy’s picture

I searched the issue queue for "system_clear_cache_submit" but didn't find where the swap occurred in March until someone updated with a comment (probably because the issue was closed last month).

There's no reasoning for why the change was made, just a swap.

Now, there's two versions of the function, and Admin menu (and any other contributed) has to work with both? Or be broken...

tobiasb’s picture

install admin menu dev or wait until the next release. June 9, 2009 -> http://drupal.org/project/cvs/108746?nid=108746&page=2&nid=108746

dave reid’s picture

That's the proper order, although we didn't really need the reference on the second parameter since it is never used. That's odd.

dave reid’s picture

Status: Active » Closed (duplicate)

Duplicate of #236657: Swapped arguments in system_clear_cache_submit function. Use either 6.x-1.x-dev or 6.x-3.x-dev until we can push another release out.