diff --git a/public/include/smarty_globals.inc.php b/public/include/smarty_globals.inc.php index 0f8fc351..f89bac11 100644 --- a/public/include/smarty_globals.inc.php +++ b/public/include/smarty_globals.inc.php @@ -128,13 +128,13 @@ $aGlobal['acl']['chat']['page'] = $setting->getValue('acl_chat_page', 2); // We don't want these session infos cached if (@$_SESSION['USERDATA']['id']) { + $aGlobal['userdata'] = $_SESSION['USERDATA']['id'] ? $user->getUserData($_SESSION['USERDATA']['id']) : array(); + $aGlobal['userdata']['balance'] = $transaction->getBalance($_SESSION['USERDATA']['id']); + // Fetch Last 5 notifications $aLastNotifications = $notification->getNofifications($_SESSION['USERDATA']['id'], 5); $aGlobal['userdata']['lastnotifications'] = $aLastNotifications; - $aGlobal['userdata'] = $_SESSION['USERDATA']['id'] ? $user->getUserData($_SESSION['USERDATA']['id']) : array(); - $aGlobal['userdata']['balance'] = $transaction->getBalance($_SESSION['USERDATA']['id']); - // Other userdata that we can cache savely $aGlobal['userdata']['shares'] = $statistics->getUserShares($_SESSION['USERDATA']['username'], $_SESSION['USERDATA']['id']); $aUserMiningStats = $statistics->getUserMiningStats($_SESSION['USERDATA']['username'], $_SESSION['USERDATA']['id']); diff --git a/public/templates/bootstrap/global/header.tpl b/public/templates/bootstrap/global/header.tpl index a8ed08c5..a461a336 100644 --- a/public/templates/bootstrap/global/header.tpl +++ b/public/templates/bootstrap/global/header.tpl @@ -15,7 +15,7 @@