diff --git a/phpBB/includes/template/twig/node/event.php b/phpBB/includes/template/twig/node/event.php index cedfa870fa..12e6ef1329 100644 --- a/phpBB/includes/template/twig/node/event.php +++ b/phpBB/includes/template/twig/node/event.php @@ -27,8 +27,6 @@ class phpbb_template_twig_node_event extends Twig_Node { $compiler->addDebugInfo($this); - $compiler->indent(); - $location = $this->getNode('expr')->getAttribute('name'); foreach ($this->environment->get_phpbb_extensions() as $ext_namespace => $ext_path) diff --git a/phpBB/includes/template/twig/twig.php b/phpBB/includes/template/twig/twig.php index 92eeb6d913..15e49df200 100644 --- a/phpBB/includes/template/twig/twig.php +++ b/phpBB/includes/template/twig/twig.php @@ -431,6 +431,13 @@ class phpbb_template_twig implements phpbb_template ) ); + // Must do this so that works correctly + // (only for the base loops, the rest are properly handled by the begin node) + foreach ($this->context->get_tpldata() as $block_name => $block_values) + { + $vars[$block_name] = !empty($block_values); + } + // cleanup unset($vars['_phpbb_blocks']['.']);