MCPcopy Create free account
hub / github.com/angular/dev-infra / cloneBody

Function cloneBody

github-actions/browserstack/set-browserstack-env.js:5777–5785  ·  view source on GitHub ↗
(instance, body)

Source from the content-addressed store, hash-verified

5775 return extractBody(object, keepalive);
5776 }
5777 function cloneBody(instance, body) {
5778 const [out1, out2] = body.stream.tee();
5779 body.stream = out1;
5780 return {
5781 stream: out2,
5782 length: body.length,
5783 source: body.source
5784 };
5785 }
5786 function throwIfAborted(state) {
5787 if (state.aborted) {
5788 throw new DOMException("The operation was aborted.", "AbortError");

Callers 2

cloneResponseFunction · 0.70
cloneRequestFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected