You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The Response object (carried by response field) in ResponseError raised by withDecoder combinator cannot be consumed (namely using .text(), .json() etc. methods) because the body stream is already read (the combinator acts on a the "response side" of a fetch request).
Description
The
Response
object (carried byresponse
field) inResponseError
raised bywithDecoder
combinator cannot be consumed (namely using.text()
,.json()
etc. methods) because the body stream is already read (the combinator acts on a the "response side" of afetch
request).Look at the spec for further information.
Current behavior
If you try to access to
response
's content of aResponseError
returned whenwithDecoder
is applied aTypeError: body used already
is thrown.Expected behavior
The
response
's content should be readable also fromwithDecoder
'sResponseError
.Environment:
Additional information
This bug has to be avoided also for other future combinators that act on "response side" of a request.
The text was updated successfully, but these errors were encountered: