permission check bug fixed

This commit is contained in:
ma0048
2025-07-23 14:14:03 +02:00
parent 9fa23a1471
commit 96cb546b68
5 changed files with 11 additions and 5 deletions
@@ -414,7 +414,9 @@ class Lehreinheit extends FHCAPI_Controller
if (isError($result))
$this->terminateWithError(getError($result), self::ERROR_TYPE_GENERAL);
$oe_array = $result;
$oe_array = [];
if (hasData($result))
$oe_array = getData($result);
if (!$this->_ci->permissionlib->isBerechtigtMultipleOe('admin', $oe_array, 'suid') &&
!$this->_ci->permissionlib->isBerechtigtMultipleOe('assistenz', $oe_array, 'suid') &&
@@ -284,7 +284,9 @@ class Lektor extends FHCAPI_Controller
if (isError($result))
$this->terminateWithError(getError($result), self::ERROR_TYPE_GENERAL);
$oe_array = $result;
$oe_array = [];
if (hasData($result))
$oe_array = getData($result);
return $this->checkPermissionGenerel($permissions, $oe_array);
}