diff --git a/application/Espo/Controllers/Admin.php b/application/Espo/Controllers/Admin.php index 5cebd2dd30..027bb02565 100644 --- a/application/Espo/Controllers/Admin.php +++ b/application/Espo/Controllers/Admin.php @@ -61,7 +61,7 @@ class Admin extends \Espo\Core\Controllers\Base public function postActionUploadUpgradePackage($params, $data) { - if ($this->getConfig('restrictedMode')) { + if ($this->getConfig()->get('restrictedMode')) { if (!$this->getUser()->get('isSuperAdmin')) { throw new Forbidden(); } @@ -79,7 +79,7 @@ class Admin extends \Espo\Core\Controllers\Base public function postActionRunUpgrade($params, $data) { - if ($this->getConfig('restrictedMode')) { + if ($this->getConfig()->get('restrictedMode')) { if (!$this->getUser()->get('isSuperAdmin')) { throw new Forbidden(); } diff --git a/application/Espo/Controllers/Extension.php b/application/Espo/Controllers/Extension.php index cbc240f493..d89a9c3ca1 100644 --- a/application/Espo/Controllers/Extension.php +++ b/application/Espo/Controllers/Extension.php @@ -58,7 +58,7 @@ class Extension extends \Espo\Core\Controllers\Record if (!$request->isPost()) { throw new Forbidden(); } - if ($this->getConfig('restrictedMode')) { + if ($this->getConfig()->get('restrictedMode')) { if (!$this->getUser()->get('isSuperAdmin')) { throw new Forbidden(); } @@ -76,7 +76,7 @@ class Extension extends \Espo\Core\Controllers\Record if (!$request->isPost()) { throw new Forbidden(); } - if ($this->getConfig('restrictedMode')) { + if ($this->getConfig()->get('restrictedMode')) { if (!$this->getUser()->get('isSuperAdmin')) { throw new Forbidden(); } @@ -112,7 +112,7 @@ class Extension extends \Espo\Core\Controllers\Record if (!$request->isDelete()) { throw BadRequest(); } - if ($this->getConfig('restrictedMode')) { + if ($this->getConfig()->get('restrictedMode')) { if (!$this->getUser()->get('isSuperAdmin')) { throw new Forbidden(); }