File tree Expand file tree Collapse file tree 1 file changed +5
-1
lines changed
src/Symfony/Component/HttpKernel/Fragment Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -46,10 +46,14 @@ public function setFragmentPath($path)
46
46
*/
47
47
protected function generateFragmentUri (ControllerReference $ reference , Request $ request )
48
48
{
49
+ // We need to forward the current _format and _locale values as we don't have
50
+ // a proper routing pattern to do the job for us.
51
+ // This makes things inconsistent if you switch from rendering a controller
52
+ // to rendering a route if the route pattern does not contain the special
53
+ // _format and _locale placeholders.
49
54
if (!isset ($ reference ->attributes ['_format ' ])) {
50
55
$ reference ->attributes ['_format ' ] = $ request ->getRequestFormat ();
51
56
}
52
-
53
57
if (!isset ($ reference ->attributes ['_locale ' ])) {
54
58
$ reference ->attributes ['_locale ' ] = $ request ->getLocale ();
55
59
}
You can’t perform that action at this time.
0 commit comments