MCPcopy Index your code
hub / github.com/nodejs/node / mustCall

Function mustCall

test/parallel/test-http2-backpressure.js:49–53  ·  view source on GitHub ↗
(fn, exact)

Source from the content-addressed store, hash-verified

47}
48
49function mustCall(fn, exact) {
50 return common.mustCall((...args) => {
51 return Promise.resolve(fn(...args)).then(common.mustCall((val) => val));
52 }, exact);
53}

Calls 3

fnFunction · 0.70
thenMethod · 0.45
resolveMethod · 0.45

Tested by 3

testFunction · 0.56
testFunction · 0.56
testFunction · 0.56

Used in the wild real call sites across dependent graphs

searching dependent graphs…