MCPcopy
hub / github.com/Effect-TS/effect / onNotification

Function onNotification

packages/sql-pg/src/PgClient.ts:364–368  ·  view source on GitHub ↗
(msg: Pg.Notification)

Source from the content-addressed store, hash-verified

362 Stream.asyncPush<string, SqlError>(Effect.fnUntraced(function*(emit) {
363 const client = yield* RcRef.get(listenClient)
364 function onNotification(msg: Pg.Notification) {
365 if (msg.channel === channel && msg.payload) {
366 emit.single(msg.payload)
367 }
368 }
369 yield* Effect.addFinalizer(() =>
370 Effect.promise(() => {
371 client.off("notification", onNotification)

Callers

nothing calls this directly

Calls 1

singleMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…