From da203429e8b78d104766e21c0151181682cb4f96 Mon Sep 17 00:00:00 2001 From: Thomas Hampe Date: Thu, 23 Sep 2021 14:09:07 +0200 Subject: [PATCH] added scope_config twig function --- Framework/View/TemplateEngine/Twig.php | 1 + 1 file changed, 1 insertion(+) diff --git a/Framework/View/TemplateEngine/Twig.php b/Framework/View/TemplateEngine/Twig.php index d7b6635..3cd5647 100644 --- a/Framework/View/TemplateEngine/Twig.php +++ b/Framework/View/TemplateEngine/Twig.php @@ -105,6 +105,7 @@ private function initTwig() 'needs_context' => true, 'is_safe' => ['html'] ])); + $this->twig->addFunction(new TwigFunction('scope_config', [$this->scopeConfig, 'getValue'])); $this->twig->addFilter(new TwigFilter('trans', '__')); $this->twig->addExtension(new DebugExtension());