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

Method publish

lib/diagnostics_channel.js:181–193  ·  view source on GitHub ↗
(data)

Source from the content-addressed store, hash-verified

179 }
180
181 publish(data) {
182 const subscribers = this._subscribers;
183 for (let i = 0; i < (subscribers?.length || 0); i++) {
184 try {
185 const onMessage = subscribers[i];
186 onMessage(data, this.name);
187 } catch (err) {
188 process.nextTick(() => {
189 triggerUncaughtException(err, false);
190 });
191 }
192 }
193 }
194
195 withStoreScope(data) {
196 return new RunStoresScope(this, data);

Callers

nothing calls this directly

Calls 1

onMessageFunction · 0.70

Tested by

no test coverage detected