Commit 18693269 authored by Dries's avatar Dries

- Patch #804328 by jcfiala, David_Rothstein: 'Compress cached pages'-setting...

- Patch #804328 by jcfiala, David_Rothstein: 'Compress cached pages'-setting should always clear cache on toggle.
parent 58a8be92
......@@ -1694,6 +1694,9 @@ function system_performance_settings() {
$form['#submit'][] = 'drupal_clear_css_cache';
$form['#submit'][] = 'drupal_clear_js_cache';
// This form allows page compression settings to be changed, which can
// invalidate the page cache, so it needs to be cleared on form submit.
$form['#submit'][] = 'system_clear_page_cache_submit';
return system_settings_form($form);
}
......@@ -1708,6 +1711,15 @@ function system_clear_cache_submit($form, &$form_state) {
drupal_set_message(t('Caches cleared.'));
}
/**
* Submit callback; clear the page cache.
*
* @ingroup forms
*/
function system_clear_page_cache_submit($form, &$form_state) {
cache_clear_all('*', 'cache_page', TRUE);
}
/**
* Form builder; Configure the site file handling.
*
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment