Commit 5844ec54 authored by tim.plunkett's avatar tim.plunkett
Browse files

Remove all calls to cache_clear_all() that pass arguments.

parent 974f5b6f
......@@ -718,7 +718,7 @@ function views_ui_add_form_save_submit($form, &$form_state) {
}
$view->save();
menu_rebuild();
cache_clear_all('*', 'cache_views', TRUE);
cache('cache_views')->flush();
cache_clear_all();
$form_state['redirect'] = 'admin/structure/views';
if (!empty($view->display['page'])) {
......@@ -2152,7 +2152,7 @@ function views_ui_edit_view_form_submit($form, &$form_state) {
menu_rebuild();
// Clear the views cache.
cache_clear_all('*', 'cache_views');
cache('cache_views')->flush();
// Clear the page cache.
cache_clear_all();
......
......@@ -1756,7 +1756,7 @@ function save() {
$this->save_locale_strings();
cache_clear_all('views_urls', 'cache_views');
cache('cache_views')->delete('views_urls');
cache_clear_all(); // clear the page cache as well.
}
......@@ -1791,7 +1791,7 @@ function delete($clear = TRUE) {
->execute();
}
cache_clear_all('views_query:' . $this->name, 'cache_views');
cache('cache_views')->delete('views_query:' . $this->name);
if ($clear) {
cache_clear_all(); // this clears the block and page caches only.
......
......@@ -149,7 +149,7 @@ function cache_get($type) {
* to be sure that we catch everything. Maybe that's a bad idea.
*/
function cache_flush() {
cache_clear_all($this->view->name . ':', $this->table, TRUE);
cache($this->table)->deletePrefix($this->view->name . ':');
}
/**
......
......@@ -592,7 +592,7 @@ function views_update_7001() {
db_delete('menu_links')
->condition('link_path', 'admin/structure/views/%', 'LIKE')
->execute();
cache_clear_all(NULL, 'cache_menu');
cache('cache_menu')->expire();
menu_rebuild();
}
}
......
......@@ -844,31 +844,31 @@ function views_flush_caches() {
* Implements hook_field_create_instance.
*/
function views_field_create_instance($instance) {
cache_clear_all('*', 'cache_views', TRUE);
cache_clear_all('*', 'cache_views_data', TRUE);
cache('cache_views')->flush();
cache('cache_views_data')->flush();
}
/**
* Implements hook_field_update_instance.
*/
function views_field_update_instance($instance, $prior_instance) {
cache_clear_all('*', 'cache_views', TRUE);
cache_clear_all('*', 'cache_views_data', TRUE);
cache('cache_views')->flush();
cache('cache_views_data')->flush();
}
/**
* Implements hook_field_delete_instance.
*/
function views_field_delete_instance($instance) {
cache_clear_all('*', 'cache_views', TRUE);
cache_clear_all('*', 'cache_views_data', TRUE);
cache('cache_views')->flush();
cache('cache_views_data')->flush();
}
/**
* Invalidate the views cache, forcing a rebuild on the next grab of table data.
*/
function views_invalidate_cache() {
cache_clear_all('*', 'cache_views', TRUE);
cache('cache_views')->flush();
}
/**
......
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