diff --git a/docs/index.bs b/docs/index.bs index c428eefd..7e258c70 100644 --- a/docs/index.bs +++ b/docs/index.bs @@ -1437,14 +1437,15 @@ spec: webappsec-referrer-policy; urlPrefix: https://w3c.github.io/webappsec-refe 1. Let |potentialResponse| be a copy of |response|'s associated [=Response/response=], except for its [=response/body=]. 1. If |response|'s [=response/body=] is non-null, run these substeps: 1. Let |reader| be the result of getting a reader from |response|'s [=response/body=]'s stream. - 1. Let |strategy| be an object created in |targetRealm|. The user agent may choose any object. + 1. Let |highWaterMark| be a non-negative, non-NaN number, chosen by the user agent. + 1. Let |sizeAlgorithm| be an algorithm that accepts a [=chunk=] object and returns a non-negative, non-NaN, non-infinite number, chosen by the user agent. 1. Let |pull| be an action that runs these subsubsteps: 1. Let |promise| be the result of reading a chunk from |response|'s [=response/body=]'s stream with |reader|. 1. When |promise| is fulfilled with an object whose done property is false and whose value property is a Uint8Array object, append the bytes represented by the value property to |bytes| and perform ! DetachArrayBuffer with the ArrayBuffer object wrapped by the value property. 1. When |promise| is fulfilled with an object whose done property is true, set |end-of-body| to true. 1. When |promise| is fulfilled with a value that matches with neither of the above patterns, or |promise| is rejected, [=ReadableStream/error=] |newStream| with a TypeError. 1. Let |cancel| be an action that [=ReadableStream/cancels=] |response|'s [=response/body=]'s stream with |reader|. - 1. Let |newStream| be the result of [=ReadableStream/construct a ReadableStream object=] with |strategy|, |pull| and |cancel| in |targetRealm|. + 1. Let |newStream| be the result of [=ReadableStream/construct a ReadableStream object=] with |highWaterMark|, |sizeAlgorithm|, |pull|, and |cancel| in |targetRealm|. 1. Set |potentialResponse|'s [=response/body=] to a new [=/body=] whose stream is |newStream|. 1. Run these subsubsteps repeatedly in parallel while |done| is false: 1. If |newStream| is errored, then set |done| to true.