Skip to content
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

rewrite options should apply to all responses #914

Open
tillsc opened this issue Nov 24, 2015 · 2 comments
Open

rewrite options should apply to all responses #914

tillsc opened this issue Nov 24, 2015 · 2 comments

Comments

@tillsc
Copy link

tillsc commented Nov 24, 2015

According to the documentation the hostRewrite and autoRewrite options only apply to 3xx responses. But the Location-Header is allowed in more than only the 3xx responses (e.g. in 201 Created).

I don't understand why it is necessary to limit this functionality to specific response codes. Why couldn't just every Location header be analyzed and replaced if there is one present in the response?

@gabrielboucher
Copy link
Contributor

I agree, this is currently biting me. We are implementing an API that tries hard to follow this specification: http://jsonapi.org/format/#crud-creating-responses especially where it says "The response SHOULD include a Location header identifying the location of the newly created resource."

However this request returns a 201 status code and the location is not being rewritten.

@jrnail23
Copy link

related: #845

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

No branches or pull requests

3 participants