This commit is contained in:
Bruno Rybársky 2024-02-03 16:34:42 +01:00
parent 6fdd76de3d
commit a2edadd640

@ -1,8 +1,14 @@
<?php
function getDynamicPermission($file): int {
global $routerConfig;
$page_tmp = include_once($file);
return $page_tmp["parameters"]["minimal_permission_level"];
$permission_level = $page_tmp["parameters"]["minimal_permission_level"];
if(!is_numeric($permission_level) || $permission_level <= 0){
$permission_level = $routerConfig["default_page_permission_level"];
}
return $permission_level;
}
function generateNavigation(): string