mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-05-09 20:12:14 +09:00
root = is_admin 취급
This commit is contained in:
parent
ddc7d31661
commit
c1d96cddd4
1 changed files with 3 additions and 3 deletions
|
|
@ -1974,7 +1974,7 @@ class moduleModel extends module
|
||||||
$privilege_list = array_keys((array) $xml_info->grant);
|
$privilege_list = array_keys((array) $xml_info->grant);
|
||||||
|
|
||||||
// Prepend default 'privilege name'
|
// Prepend default 'privilege name'
|
||||||
// is_admin, manager, is_site_admin not distinguish because of compatibility.
|
// manager, is_site_admin not distinguish because of compatibility.
|
||||||
array_unshift($privilege_list, 'access', 'is_admin', 'manager', 'is_site_admin', 'root');
|
array_unshift($privilege_list, 'access', 'is_admin', 'manager', 'is_site_admin', 'root');
|
||||||
|
|
||||||
// Unique
|
// Unique
|
||||||
|
|
@ -1988,8 +1988,8 @@ class moduleModel extends module
|
||||||
{
|
{
|
||||||
$grant->{$val} = true;
|
$grant->{$val} = true;
|
||||||
}
|
}
|
||||||
// If a module manager, grant all (except 'root')
|
// If a module manager, grant all (except 'root', 'is_admin')
|
||||||
else if($is_module_admin === true && $val !== 'root')
|
else if($is_module_admin === true && $val !== 'root' && $val !== 'is_admin')
|
||||||
{
|
{
|
||||||
$grant->{$val} = true;
|
$grant->{$val} = true;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue