diff --git a/system/twig.php b/system/twig.php index 0222353a..12189638 100644 --- a/system/twig.php +++ b/system/twig.php @@ -95,7 +95,14 @@ $function = new TwigFunction('hook', function ($context, $hook, array $params = global $hooks; if(is_string($hook)) { - $hook = constant($hook); + if (defined($hook)) { + $hook = constant($hook); + } + else { + // plugin/template has a hook that this version of myaac does not support + // just silently return + return; + } } $params['context'] = $context;