[BUGFIX] VariableContainer should be available in getLayoutName 39/40539/2
authorChristian Müller <christian@flownative.com>
Thu, 18 Jun 2015 09:49:38 +0000 (11:49 +0200)
committerHelmut Hummel <helmut.hummel@typo3.org>
Mon, 22 Jun 2015 19:28:03 +0000 (21:28 +0200)
The ``currentVariableContainer`` was not made available in
the ``getLayoutName`` method of compiled templates leading to errors
when the layout name was a variable.

Releases: master
Resolves: #67595
Change-Id: Ib0100b120440b8daf83ae30c8043f3ab0cd7ff3b
Reviewed-on: http://review.typo3.org/40539
Reviewed-by: Helmut Hummel <helmut.hummel@typo3.org>
Tested-by: Helmut Hummel <helmut.hummel@typo3.org>
typo3/sysext/fluid/Classes/Core/Compiler/TemplateCompiler.php

index c4ebb66..fd9a0c1 100644 (file)
@@ -91,6 +91,7 @@ public function getVariableContainer() {
        return new \TYPO3\CMS\Fluid\Core\ViewHelper\TemplateVariableContainer();
 }
 public function getLayoutName(\TYPO3\CMS\Fluid\Core\Rendering\RenderingContextInterface \$renderingContext) {
+\$currentVariableContainer = \$renderingContext->getTemplateVariableContainer();
 %s
 return %s;
 }