Closed
Description
If you try to use a Request object as window.fetch param, js will crash because:
if (!arguments[0].match(new RegExp({{ excluded_ajax_paths|json_encode|raw }}))) {
One easy solution is something like this before that line (line ~246, /symfony/symfony/src/Symfony/Bundle/WebProfilerBundle/Resources/views/Profiler/base_js.html.twig)
var paramType = Object.prototype.toString.call(arguments[0]);
if (paramType === '[object Request]') {
arguments[0] = arguments[0].url;
arguments[1] = {
method: arguments[0].method,
credentials: arguments[0].credentials,
headers: arguments[0].headers,
mode: arguments[0].mode,
redirect: arguments[0].redirect
};
}
At least that's working for me, but it needs more testing.