diff options
Diffstat (limited to 'lib/private/legacy/util.php')
-rw-r--r-- | lib/private/legacy/util.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/private/legacy/util.php b/lib/private/legacy/util.php index 5ef1130d361..82fb07eb95a 100644 --- a/lib/private/legacy/util.php +++ b/lib/private/legacy/util.php @@ -137,7 +137,7 @@ class OC_Util { // If we are not forced to load a specific user we load the one that is logged in if ($user === null) { $user = ''; - } else if ($user == "" && OC_User::isLoggedIn()) { + } else if ($user == "" && \OC::$server->getUserSession()->isLoggedIn()) { $user = OC_User::getUser(); } @@ -971,7 +971,7 @@ class OC_Util { */ public static function checkLoggedIn() { // Check if we are a user - if (!OC_User::isLoggedIn()) { + if (!\OC::$server->getUserSession()->isLoggedIn()) { header('Location: ' . \OC::$server->getURLGenerator()->linkToRoute( 'core.login.showLoginForm', [ |