Closed
Bug 1514883
Opened 6 years ago
Closed 6 years ago
new Request().body returns undefined, against fetch spec
Categories
(Core :: DOM: Core & HTML, defect)
Tracking
()
RESOLVED
DUPLICATE
of bug 1387483
People
(Reporter: michael.hart.au, Unassigned)
Details
User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.110 Safari/537.36
Steps to reproduce:
Typed the following in the web console:
new Request('https://www.mozilla.org', {method: 'POST', body: 'hi'}).body
Actual results:
It returned `undefined`
Similarly, obviously:
new Request('https://www.mozilla.org', {method: 'POST', body: 'hi'}).body.getReader()
Throws a `... body is undefined` error
Expected results:
According to the fetch spec, Request should implement the Body mixin, which means it should have a `body` property:
https://fetch.spec.whatwg.org/#dom-body-body
https://developer.mozilla.org/en-US/docs/Web/API/Request
And this property should return a ReadableStream if the body exists.
Comment 1•6 years ago
|
||
I could reproduce the issue on
User Agent Mozilla/5.0 (Macintosh; Intel Mac OS X 10.14; rv:66.0) Gecko/20100101 Firefox/66.0
Status: UNCONFIRMED → NEW
Component: Untriaged → DOM
Ever confirmed: true
Product: Firefox → Core
Updated•6 years ago
|
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → DUPLICATE
Assignee | ||
Updated•6 years ago
|
Component: DOM → DOM: Core & HTML
You need to log in
before you can comment on or make changes to this bug.
Description
•