Skip to content
This repository has been archived by the owner on Jun 6, 2024. It is now read-only.

node-fetch resolves the location header instead of leaving it as is #154

Open
cdloh opened this issue Aug 26, 2020 · 0 comments
Open

node-fetch resolves the location header instead of leaving it as is #154

cdloh opened this issue Aug 26, 2020 · 0 comments

Comments

@cdloh
Copy link

cdloh commented Aug 26, 2020

Tried to create an issue on the other repo but cannot.

Within node-fetch if the fetch operation returns a redirect node-fetch resolves the URL which means relative URLs aren't left as is. This is different from what the fetch API does within CF (and all browsers).

				const locationURL = location === null ? null : url.resolve(request.url, location);

It should be left as is.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant