fix settings restriction

This commit is contained in:
Yuri Kuznetsov
2021-10-01 18:41:44 +03:00
parent a1570c7666
commit f07895eeb0

View File

@@ -196,14 +196,16 @@ class Settings
foreach ($this->access->getAdminParamList() as $item) {
$ignoreItemList[] = $item;
}
}
if ($this->config->get('restrictedMode') && !$user->isSuperAdmin()) {
foreach ($this->access->getSuperAdminParamList() as $item) {
$ignoreItemList[] = $item;
}
}
if ($this->config->get('restrictedMode') && !$user->isSuperAdmin()) {
// @todo Maybe add restriction level for non-super admins.
}
foreach ($ignoreItemList as $item) {
unset($data->$item);
}