function UserHooks::userLogout

Same name and namespace in other branches
  1. 11.x core/modules/user/src/Hook/UserHooks.php \Drupal\user\Hook\UserHooks::userLogout()

Implements hook_user_logout().

Attributes

File

core/modules/user/src/Hook/UserHooks.php, line 216

Class

UserHooks
Hook implementations for user.

Namespace

Drupal\user\Hook

Code

public function userLogout(AccountInterface $account) : void {
  // Reset default theme variables.
  \Drupal::service('theme.manager')->resetActiveTheme();
}

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