Changeset View
Changeset View
Standalone View
Standalone View
core/kernel/application.php
Show First 20 Lines • Show All 2598 Lines • ▼ Show 20 Line(s) | |||||
* @return boolean | * @return boolean | ||||
*/ | */ | ||||
public function permissionCheckingDisabled($user_id = null) | public function permissionCheckingDisabled($user_id = null) | ||||
{ | { | ||||
if ( !isset($user_id) ) { | if ( !isset($user_id) ) { | ||||
$user_id = $this->RecallVar('user_id'); | $user_id = $this->RecallVar('user_id'); | ||||
} | } | ||||
return $user_id == USER_ROOT; | return $user_id == USER_ROOT || $user_id == USER_SYSTEM; | ||||
alex: Code is executed during tests, but I have no idea how to test its result. | |||||
} | } | ||||
/** | /** | ||||
* Check current user permissions based on it's group permissions in specified category | * Check current user permissions based on it's group permissions in specified category | ||||
* | * | ||||
* @param string $name permission name | * @param string $name permission name | ||||
* @param int $cat_id category id, current used if not specified | * @param int $cat_id category id, current used if not specified | ||||
* @param int $type permission type {1 - system, 0 - per category} | * @param int $type permission type {1 - system, 0 - per category} | ||||
▲ Show 20 Lines • Show All 532 Lines • Show Last 20 Lines |
Code is executed during tests, but I have no idea how to test its result.