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

Method done

lib/internal/http2/core.js:2294–2304  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

2292 let writeCallbackErr;
2293 let endCheckCallbackErr;
2294 const done = () => {
2295 if (waitingForEndCheck || waitingForWriteCallback) return;
2296 const err = aggregateTwoErrors(endCheckCallbackErr, writeCallbackErr);
2297 // writeGeneric does not destroy on error and
2298 // we cannot enable autoDestroy,
2299 // so make sure to destroy on error.
2300 if (err) {
2301 this.destroy(err);
2302 }
2303 cb(err);
2304 };
2305 const writeCallback = (err) => {
2306 waitingForWriteCallback = false;
2307 writeCallbackErr = err;

Callers 15

showNodesFunction · 0.45
runNextFunction · 0.45
AbortSignal.any.jsFile · 0.45
step3Function · 0.45
step6Function · 0.45
step6Function · 0.45
step6Function · 0.45

Calls 3

aggregateTwoErrorsFunction · 0.85
cbFunction · 0.50
destroyMethod · 0.45

Tested by 2

testFunction · 0.36
testFunction · 0.36