function ThemeRegistry::resolveCacheMiss

Same name in other branches
  1. 7.x includes/theme.inc \ThemeRegistry::resolveCacheMiss()
  2. 9 core/lib/Drupal/Core/Utility/ThemeRegistry.php \Drupal\Core\Utility\ThemeRegistry::resolveCacheMiss()
  3. 8.9.x core/lib/Drupal/Core/Utility/ThemeRegistry.php \Drupal\Core\Utility\ThemeRegistry::resolveCacheMiss()
  4. 11.x core/lib/Drupal/Core/Utility/ThemeRegistry.php \Drupal\Core\Utility\ThemeRegistry::resolveCacheMiss()

Overrides CacheCollector::resolveCacheMiss

1 call to ThemeRegistry::resolveCacheMiss()
ThemeRegistry::get in core/lib/Drupal/Core/Utility/ThemeRegistry.php
Gets value from the cache.

File

core/lib/Drupal/Core/Utility/ThemeRegistry.php, line 122

Class

ThemeRegistry
Builds the run-time theme registry.

Namespace

Drupal\Core\Utility

Code

public function resolveCacheMiss($key) {
    if (!isset($this->completeRegistry)) {
        $this->completeRegistry = \Drupal::service('theme.registry')->get();
    }
    $this->storage[$key] = $this->completeRegistry[$key];
    if ($this->persistable) {
        $this->persist($key);
    }
    return $this->storage[$key];
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.