diff options
author | Thomas Müller <thomas.mueller@tmit.eu> | 2013-10-31 04:59:50 -0700 |
---|---|---|
committer | Thomas Müller <thomas.mueller@tmit.eu> | 2013-10-31 04:59:50 -0700 |
commit | 1b1859c4ea569b6ac3f12658e5d3eafd8b7f2a7c (patch) | |
tree | 8ffced0f9be5739cd6910827bf32f635600869d3 /lib | |
parent | 2d643a7c8d789a9758394075f83b0626674fb269 (diff) | |
parent | 5ca03f851ee83156d5ef3623a7579707dc52518b (diff) | |
download | nextcloud-server-1b1859c4ea569b6ac3f12658e5d3eafd8b7f2a7c.tar.gz nextcloud-server-1b1859c4ea569b6ac3f12658e5d3eafd8b7f2a7c.zip |
Merge pull request #5574 from owncloud/fixing-5271-stable5
we should check if a user is logged in before we check for admin privile...
Diffstat (limited to 'lib')
-rwxr-xr-x | lib/util.php | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/util.php b/lib/util.php index 9ba1bdb0282..12c399695dc 100755 --- a/lib/util.php +++ b/lib/util.php @@ -404,6 +404,7 @@ class OC_Util { * Check if the user is a admin, redirects to home if not */ public static function checkAdminUser() { + \OC_Util::checkLoggedIn(); if( !OC_User::isAdminUser(OC_User::getUser())) { header( 'Location: '.OC_Helper::linkToAbsolute( '', 'index.php' )); exit(); @@ -436,6 +437,7 @@ class OC_Util { * @return array $groups where the current user is subadmin */ public static function checkSubAdminUser() { + \OC_Util::checkLoggedIn(); if(!OC_SubAdmin::isSubAdmin(OC_User::getUser())) { header( 'Location: '.OC_Helper::linkToAbsolute( '', 'index.php' )); exit(); |