diff options
Diffstat (limited to 'inc/user.inc.php')
-rw-r--r-- | inc/user.inc.php | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/inc/user.inc.php b/inc/user.inc.php index f12cc39f..2571c61c 100644 --- a/inc/user.inc.php +++ b/inc/user.inc.php @@ -90,8 +90,12 @@ class User return PermissionUtil::getAllowedLocations(self::$user['userid'], $permission); } if (self::$user['permissions'] & Permission::get('superadmin')) { - $a = array_keys(Location::getLocationsAssoc()); - $a[] = 0; + if (Module::isAvailable('locations')) { + $a = array_keys(Location::getLocationsAssoc()); + $a[] = 0; + } else { + $a = [0]; + } return $a; } return array(); |