function ExtensionList::reset
Same name in other branches
- 8.9.x core/lib/Drupal/Core/Extension/ExtensionList.php \Drupal\Core\Extension\ExtensionList::reset()
- 10 core/lib/Drupal/Core/Extension/ExtensionList.php \Drupal\Core\Extension\ExtensionList::reset()
- 11.x core/lib/Drupal/Core/Extension/ExtensionList.php \Drupal\Core\Extension\ExtensionList::reset()
Resets the stored extension list.
We don't reset statically added filenames, as it is a static cache which logically can't change. This is done for performance reasons of the installer.
Return value
$this
1 call to ExtensionList::reset()
- ThemeExtensionList::reset in core/
lib/ Drupal/ Core/ Extension/ ThemeExtensionList.php - Resets the stored extension list.
1 method overrides ExtensionList::reset()
- ThemeExtensionList::reset in core/
lib/ Drupal/ Core/ Extension/ ThemeExtensionList.php - Resets the stored extension list.
File
-
core/
lib/ Drupal/ Core/ Extension/ ExtensionList.php, line 163
Class
- ExtensionList
- Provides available extensions.
Namespace
Drupal\Core\ExtensionCode
public function reset() {
$this->extensions = NULL;
$this->cache
->delete($this->getListCacheId());
$this->extensionInfo = NULL;
$this->cache
->delete($this->getInfoCacheId());
$this->pathNames = NULL;
try {
$this->state
->delete($this->getPathnamesCacheId());
} catch (DatabaseExceptionWrapper $e) {
// Ignore exceptions caused by a non existing {key_value} table in the
// early installer.
}
$this->cache
->delete($this->getPathnamesCacheId());
// @todo In the long run it would be great to add the reset, but the early
// installer fails due to that. https://www.drupal.org/node/2719315 could
// help to resolve with that.
return $this;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.