8000 [WebProfilerBundle] fix wrong url when base path is the index by ismail1432 · Pull Request #28183 · symfony/symfony · GitHub
[go: up one dir, main page]

Skip to content

[WebProfilerBundle] fix wrong url when base path is the index #28183

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Sep 4, 2018
Merged

[WebProfilerBundle] fix wrong url when base path is the index #28183

merged 1 commit into from
Sep 4, 2018

Conversation

ismail1432
Copy link
Contributor
Q A
Branch? >= 3.4
Bug fix? yes
New feature? no
BC breaks? no
Deprecations? no
Tests pass? yes
Fixed tickets #27846
License MIT

The FileLinkFormatter create a wrong url because it's using getBaseUrl that render the script filename, the problem is that in this class it's used twice, first time with the getBaseUrl method and another time with the generate method. Just switch to getBasePath solve the issue.
WDYT ?

@ismail1432 ismail1432 changed the title [WebProfiler] Wrong URL file [WebProfilerBundle] fix wrong url when base path is the index Aug 11, 2018
@nicolas-grekas nicolas-grekas added this to the 3.4 milestone Aug 19, 2018
@nicolas-grekas nicolas-grekas changed the base branch from master to 3.4 August 19, 2018 09:32
@nicolas-grekas nicolas-grekas changed the base branch from 3.4 to master August 19, 2018 09:32
@nicolas-grekas
Copy link
Member

If this is for 3.4, can you rebase + retarget 3.4 please?

@ismail1432 ismail1432 changed the base branch from master to 3.4 August 26, 2018 10:40
@ismail1432 ismail1432 changed the base branch from 3.4 to master August 26, 2018 10:40
Copy link
Member
@fabpot fabpot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

for 3.4

@fabpot fabpot changed the base branch from master to 3.4 September 4, 2018 07:18
@fabpot
Copy link
Member
fabpot commented Sep 4, 2018

Thank you @ismail1432.

@fabpot fabpot merged commit 897615e into symfony:3.4 Sep 4, 2018
fabpot added a commit that referenced this pull request Sep 4, 2018
…dex (ismail1432)

This PR was submitted for the master branch but it was merged into the 3.4 branch instead (closes #28183).

Discussion
----------

[WebProfilerBundle] fix wrong url when base path is the index

| Q             | A
| ------------- | ---
| Branch?       | >= 3.4
| Bug fix?      | yes
| New feature?  | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks?    | no
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | #27846   <!-- #-prefixed issue number(s), if any -->
| License       | MIT

The `FileLinkFormatter` create a wrong url because it's using [getBaseUrl](https://github.com/symfony/symfony/blob/master/src/Symfony/Component/HttpFoundation/Request.php#L870) that render the script filename, the problem is that in this class it's used twice, first time with the [getBaseUrl method](https://github.com/symfony/symfony/blob/master/src/Symfony/Component/HttpKernel/Debug/FileLinkFormatter.php#L99) and another time with the [generate method](https://github.com/symfony/symfony/blob/master/src/Symfony/Component/HttpKernel/Debug/FileLinkFormatter.php#L77). Just switch to `getBasePath` solve the issue.
WDYT ?

Commits
-------

897615e change baseUrl to basePath to fix wrong profiler url
This was referenced Sep 30, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants
0