public function LocaleTranslation::reset in Drupal 8
Same name and namespace in other branches
- 9 core/modules/locale/src/LocaleTranslation.php \Drupal\locale\LocaleTranslation::reset()
- 10 core/modules/locale/src/LocaleTranslation.php \Drupal\locale\LocaleTranslation::reset()
Resets translation cache.
Since most translation systems implement some form of caching, this provides a way to delete that cache.
Overrides TranslatorInterface::reset
File
- core/
modules/ locale/ src/ LocaleTranslation.php, line 141
Class
- LocaleTranslation
- String translator using the locale module.
Namespace
Drupal\localeCode
public function reset() {
unset($this->translateEnglish);
$this->translations = [];
}