Issue #2541340 by dawehner: Remove dead code from user module

8.0.x
Alex Pott 2015-07-30 15:33:48 +01:00
parent 6feb57b3ac
commit 6366f77221
1 changed files with 0 additions and 6 deletions

View File

@ -417,12 +417,6 @@ function user_format_name(AccountInterface $account) {
function user_template_preprocess_default_variables_alter(&$variables) {
$user = \Drupal::currentUser();
// If this function is called from the installer after Drupal has been
// installed then $user will not be set.
if (!is_object($user)) {
return;
}
$variables['user'] = clone $user;
// Remove password and session IDs, $form_state, since themes should not need nor see them.
unset($variables['user']->pass, $variables['user']->sid, $variables['user']->ssid);