diff --git a/system/init.php b/system/init.php index 8237e030..03a323ae 100644 --- a/system/init.php +++ b/system/init.php @@ -51,6 +51,7 @@ $hooks = app()->get('hooks'); require_once SYSTEM . 'twig.php'; // action, used by many pages +global $action; $action = $_REQUEST['action'] ?? ''; define('ACTION', $action); diff --git a/system/src/Services/RouterService.php b/system/src/Services/RouterService.php index caf15956..a7d81ab1 100644 --- a/system/src/Services/RouterService.php +++ b/system/src/Services/RouterService.php @@ -9,7 +9,7 @@ class RouterService { public function handleRouting(): array { - global $content, $template_path, $template; + global $content, $template_path, $template, $canEdit, $action; $db = app()->get('database'); $twig = app()->get('twig');