hook_themes_uninstalled

hook_themes_uninstalled(array $themes)

Respond to themes being uninstalled.

Parameters

array $theme_list: Array containing the names of the themes being uninstalled.

See also

\Drupal\Core\Extension\ThemeHandler::uninstall()

Related topics

Hooks
Define functions that alter the behavior of Drupal core.

File

core/lib/Drupal/Core/Render/theme.api.php, line 742
Hooks and documentation related to the theme and render system.

Code

function hook_themes_uninstalled(array $themes) {
  // Remove some state entries depending on the theme.
  foreach ($themes as $theme) {
    \Drupal::state()->delete('example.' . $theme);
  }
}
doc_Drupal
2016-10-29 09:18:31
Comments
Leave a Comment

Please login to continue.