-
Notifications
You must be signed in to change notification settings - Fork 2.8k
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
Response.body is always undefined #1454
Comments
joshmossas
changed the title
Spec expects Response.body to be defined
Response.body is always undefined
May 7, 2024
Hello @JakeChampion , any progress on this proposal ? |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The fetch standard says that
response.body
should benull
or abody
.https://fetch.spec.whatwg.org/#responses
However this polyfill never sets the body field in
Response
so it's alwaysundefined
. This causes downstream issues for applications that might useresponse.body
to check if a response body exists.Proposed Change
In
fetch.js
line 238fetch/fetch.js
Line 238 in ba5cf1e
assign the body field
I'm willing to open a PR if this proposal looks good to you.
The text was updated successfully, but these errors were encountered: