MCPcopy
hub / github.com/nodejs/undici / writeBody

Function writeBody

test/cache-interceptor/cache-store-test-utils.js:396–403  ·  view source on GitHub ↗

* @param {import('node:stream').Writable} stream * @param {Buffer[]} body

(stream, body)

Source from the content-addressed store, hash-verified

394 * @param {Buffer[]} body
395 */
396function writeBody (stream, body) {
397 for (const chunk of body) {
398 stream.write(chunk)
399 }
400
401 stream.end()
402 return stream
403}
404
405/**
406 * @param {import('../../types/cache-interceptor.d.ts').default.GetResult} param0

Callers 2

cacheStoreTestsFunction · 0.85

Calls 2

writeMethod · 0.45
endMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…