You are here

public function Registry::reset in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 core/lib/Drupal/Core/Theme/Registry.php \Drupal\Core\Theme\Registry::reset()

Invalidates theme registry caches.

To be called when the list of enabled extensions is changed.

File

core/lib/Drupal/Core/Theme/Registry.php, line 718
Contains \Drupal\Core\Theme\Registry.

Class

Registry
Defines the theme registry service.

Namespace

Drupal\Core\Theme

Code

public function reset() {

  // Reset the runtime registry.
  if (isset($this->runtimeRegistry) && $this->runtimeRegistry instanceof ThemeRegistry) {
    $this->runtimeRegistry
      ->clear();
  }
  $this->runtimeRegistry = NULL;
  $this->registry = NULL;
  Cache::invalidateTags(array(
    'theme_registry',
  ));
  return $this;
}