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

Method wrappedCallback

lib/diagnostics_channel.js:600–612  ·  view source on GitHub ↗
(err, res)

Source from the content-addressed store, hash-verified

598 const continuationWindow = this.#continuationWindow;
599
600 function wrappedCallback(err, res) {
601 if (err) {
602 context.error = err;
603 error.publish(context);
604 } else {
605 context.result = res;
606 }
607
608 // Use continuation window for asyncStart/asyncEnd around callback
609 // eslint-disable-next-line no-unused-vars
610 using scope = continuationWindow.withScope(context);
611 return ReflectApply(callback, this, arguments);
612 }
613
614 const callback = ArrayPrototypeAt(args, position);
615 validateFunction(callback, 'callback');

Callers

nothing calls this directly

Calls 2

publishMethod · 0.45
withScopeMethod · 0.45

Tested by

no test coverage detected