-
-
Notifications
You must be signed in to change notification settings - Fork 9.7k
Description
This is related to the old issue #2653, that has returned after Symfony 2.3.
(In this example I've just added code to the AcmeDemoBundle to make it easier to reproduce):
Twig code added to AcmeDemoShopBundle:Demo:index.html.twig:
{{ render (controller('AcmeDemoBundle:Demo:hello2', {'_format' : 'otherformat'})) }}
Controller code added to Acme\DemoBundle\Controller\DemoController:
/*
@route("/hello2.{_format}", name="_demo_hello2", defaults={"_format" = "defaultformat"})
@template()
*/
public function hello2Action($_format) {
return array('_format' => $_format);
}
When the Twig template calls the render function the _format parameter is ignored and the controller always see "html" instead 'otherformat' (specified in the render function).
The bug has been introduced in 2.3-dev after revision f03a489 (as this one still works, but last 2.3 doesn't)