Skip to content

Fix redirection with nginx and http2 #546

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
Nov 12, 2022
Merged

Fix redirection with nginx and http2 #546

merged 1 commit into from
Nov 12, 2022

Conversation

xaviermarchegay
Copy link
Contributor

Q A
Bug fix? yes
New feature? no
Tickets Fix #543
License MIT

Let’s drop the header during the redirect (which is when we have an empty body) and, instead, add a 2nd header - something custom like X-Live-Redirect. Then, in the javascript, only throw the error of the content-type is wrong/missing AND that special header is missing.

I’d welcome a PR of you’re open to it :)

Copy link
Member

@weaverryan weaverryan left a comment

Choose a reason for hiding this comment

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

That was EXACTLY what I had in mind

@weaverryan
Copy link
Member

Thanks Xavier!

@weaverryan weaverryan merged commit 843f1dd into symfony:2.x Nov 12, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Live] With nginx and http2, the "Content-Type" header is stripped in a 204 response
2 participants