From 8c3cb0e06f9709c1de3398b48221241e7cbdd310 Mon Sep 17 00:00:00 2001 From: slawkens Date: Sat, 11 Oct 2025 18:34:15 +0200 Subject: [PATCH] New configurable: hooks_debug To view where hooks are located in .twig files --- system/twig.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/system/twig.php b/system/twig.php index ecc7a957..89f25939 100644 --- a/system/twig.php +++ b/system/twig.php @@ -101,7 +101,9 @@ $twig->addFunction($function); $function = new TwigFunction('hook', function ($context, $hook, array $params = []) { global $hooks; - //note($hook); + if (config('hooks_debug')) { + note($hook); + } if(is_string($hook)) { if (defined($hook)) {