add link for null body

This commit is contained in:
fyears 2024-01-01 01:32:22 +08:00
parent 200d25de70
commit bbb909cda4

View File

@ -100,6 +100,7 @@ if (VALID_REQURL) {
let r2: Response = undefined; let r2: Response = undefined;
if ([101, 103, 204, 205, 304].includes(r.status)) { if ([101, 103, 204, 205, 304].includes(r.status)) {
// A null body status is a status that is 101, 103, 204, 205, or 304. // A null body status is a status that is 101, 103, 204, 205, or 304.
// https://fetch.spec.whatwg.org/#statuses
// fix this: Failed to construct 'Response': Response with null body status cannot have body // fix this: Failed to construct 'Response': Response with null body status cannot have body
r2 = new Response(null, { r2 = new Response(null, {
status: r.status, status: r.status,