MCPcopy
hub / github.com/nock/nock / getDecompressedGetBody

Function getDecompressedGetBody

lib/utils/node/index.js:15–20  ·  view source on GitHub ↗

* @param {Request} request * @returns {ArrayBuffer} * Returns the request body stream of the given request. * @note This is only relevant in the context of `http.ClientRequest`. * This function will throw if the given `request` wasn't created based on * the `http.ClientRequest` instance. * You

(request)

Source from the content-addressed store, hash-verified

13 * You must rely on the web stream consumers for other request clients.
14 */
15function getDecompressedGetBody(request) {
16 if (request.method !== 'GET') {
17 throw new Error('The request method must be GET')
18 }
19 return Readable.from(Reflect.get(request, kDecompressedGetBody))
20}
21
22/**
23 * @param {Request} request

Callers 1

test_intercept.jsFile · 0.85

Calls 1

getMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…