mirror of
https://github.com/phpbb/phpbb.git
synced 2025-08-01 22:40:39 +02:00
[feature/twig] Fix <!-- .blah since the being node was changed
PHPBB3-11598
This commit is contained in:
@@ -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)
|
||||
|
@@ -431,6 +431,13 @@ class phpbb_template_twig implements phpbb_template
|
||||
)
|
||||
);
|
||||
|
||||
// Must do this so that <!-- IF .blah --> 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']['.']);
|
||||
|
||||
|
Reference in New Issue
Block a user