From 5309e64949c76e457ac4296c072b6d4847053208 Mon Sep 17 00:00:00 2001 From: Molkobain Date: Mon, 8 Jul 2019 16:55:23 +0200 Subject: [PATCH] Fix toolbar load when GET params are present in "_wdt" route When using a custom router that inject GET parameters, eg: ``` # services.yaml parameters: # Replace default url generator service router.options.generator_base_class: Combodo\iTop\Portal\Routing\UrlGenerator ``` The path generated by the toolbar JS is HTML entity encoded which breaks the JS call (`&` becomes `&`). --- .../Resources/views/Profiler/toolbar_js.html.twig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Symfony/Bundle/WebProfilerBundle/Resources/views/Profiler/toolbar_js.html.twig b/src/Symfony/Bundle/WebProfilerBundle/Resources/views/Profiler/toolbar_js.html.twig index f13edfcfeb..9da75d0559 100644 --- a/src/Symfony/Bundle/WebProfilerBundle/Resources/views/Profiler/toolbar_js.html.twig +++ b/src/Symfony/Bundle/WebProfilerBundle/Resources/views/Profiler/toolbar_js.html.twig @@ -15,7 +15,7 @@ Sfjs.load( 'sfwdt{{ token }}', - '{{ path("_wdt", { "token": token }) }}', + '{{ path("_wdt", { "token": token })|escape('js') }}', function(xhr, el) { /* Evaluate embedded scripts inside the toolbar */