Skip to content

[WebProfilerBundle] Wrong URL file #27846

@yceruto

Description

@yceruto

Symfony version(s) affected: 3.4+

Description
After these changes https://github.com/symfony/symfony/pull/26758/files#diff-9b36be9db6ed4f3c306cb876b1f134c5R84 the base url is rendered twice:

first here:

return $router->generate($routeName).$queryString;

$url = $schemeAuthority.$this->context->getBaseUrl().$url;

later here:

$request->getSchemeAndHttpHost().$request->getBaseUrl().$this->urlFormat,

Note the /index.php/index.php/ part:
filelink2

How to reproduce
Clone the https://github.com/symfony/demo project and click over any file link in profiler or toolbar to open it into Web code viewer.

Possible Solution
I'm not sure, probably we should check the base url in $this->urlFormat before return it.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions