mirror of
https://github.com/twigphp/Twig.git
synced 2026-09-15 03:46:39 +00:00
fixed end of constructor node logic
This commit is contained in:
@@ -102,7 +102,7 @@ class SandboxNodeVisitor extends AbstractNodeVisitor
|
|||||||
if ($node instanceof ModuleNode) {
|
if ($node instanceof ModuleNode) {
|
||||||
$this->inAModule = false;
|
$this->inAModule = false;
|
||||||
|
|
||||||
$node->setNode('constructor_end', new Node([new CheckSecurityNode($this->filters, $this->tags, $this->functions), $node->getNode('display_start')]));
|
$node->getNode('constructor_end')->setNode('_security_check', new Node([new CheckSecurityNode($this->filters, $this->tags, $this->functions), $node->getNode('display_start')]));
|
||||||
} elseif ($this->inAModule) {
|
} elseif ($this->inAModule) {
|
||||||
if ($node instanceof PrintNode || $node instanceof SetNode) {
|
if ($node instanceof PrintNode || $node instanceof SetNode) {
|
||||||
$this->needsToStringWrap = false;
|
$this->needsToStringWrap = false;
|
||||||
|
|||||||
Reference in New Issue
Block a user