1.20.x token.inc token_cache_clear()

Clear token caches and static variables.

File

includes/token.inc, line 381
Backdrop placeholder/token replacement system.

Code

function token_cache_clear() {
  if (db_table_exists('cache_token')) {
    cache('token')->flush();
  }
  backdrop_static_reset('token_get_info');
  backdrop_static_reset('token_get_global_token_types');
  backdrop_static_reset('token_build_tree');
  backdrop_static_reset('_menu_token_link_load');
  backdrop_static_reset('_menu_token_node_link_load');
  backdrop_static_reset('_field_token_info');
}