Function that creates an error from a response. Can be sync or async to allow reading response body.
The fetch response that triggered the error
The error to throw, or a Promise resolving to the error
Function that creates an error from a response. Can be sync or async to allow reading response body.