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

Function ensureJournal

packages/experimental/src/EventLogServer.ts:226–232  ·  view source on GitHub ↗
(publicKey: string)

Source from the content-addressed store, hash-verified

224 const journals = new Map<string, Array<EncryptedRemoteEntry>>()
225 const remoteId = makeRemoteId()
226 const ensureJournal = (publicKey: string) => {
227 let journal = journals.get(publicKey)
228 if (journal) return journal
229 journal = []
230 journals.set(publicKey, journal)
231 return journal
232 }
233 const pubsubs = yield* RcMap.make({
234 lookup: (_publicKey: string) =>
235 Effect.acquireRelease(

Callers 1

EventLogServer.tsFile · 0.85

Calls 2

getMethod · 0.65
setMethod · 0.65

Tested by

no test coverage detected