diff --git a/web/ajax/modals/logout.php b/web/ajax/modals/logout.php index a0648a70c..e9066795d 100644 --- a/web/ajax/modals/logout.php +++ b/web/ajax/modals/logout.php @@ -43,8 +43,8 @@ global $CLANG; fetch(PDO::FETCH_ASSOC) ) { $_SESSION = array(); - if ( ! session_decode($row['data']) ) { - ZM\Warning('Failed to decode ' . $row['data']); + if (!session_decode($row['data'])) { + ZM\Warning('Failed to decode '.$row['data']); continue; } - ZM\Debug(print_r($_SESSION, true)); - if ( isset($_SESSION['last_time']) ) { + if (isset($_SESSION['last_time'])) { # This is a dead session continue; } - if ( !isset($_SESSION['username']) ) { + if (!isset($_SESSION['username'])) { # Not logged in continue; } - if ( isset($user_cache[$_SESSION['username']]) ) { + if (isset($user_cache[$_SESSION['username']])) { $user = $user_cache[$_SESSION['username']]; } else { $user = ZM\User::find_one(array('Username'=>$_SESSION['username'])); - if ( ! $user ) { - ZM\Debug('User not found for ' . $_SESSION['username']); + if (!$user) { + ZM\Debug('User not found for '.$_SESSION['username']); continue; } $user_cache[$_SESSION['username']] = $user;