Update user cache.

pull/2487/head
jmontoyaa 7 years ago
parent 4709be2b9b
commit ed181a66de
  1. 11
      main/inc/global.inc.php

@ -495,6 +495,17 @@ if (!empty($valid_languages)) {
$userEntity->setLanguage($language_interface);
Database::getManager()->merge($userEntity);
Database::getManager()->flush();
// Update cache
api_get_user_info(
api_get_user_id(),
true,
false,
true,
false,
true,
true
);
if (isset($_SESSION['_user'])) {
$_SESSION['_user']['language'] = $language_interface;
}

Loading…
Cancel
Save