Small tweaks to subscriptions

This commit is contained in:
Jon Staab
2024-12-02 15:49:55 -08:00
parent d52b192daa
commit 134692e5a1
3 changed files with 12 additions and 17 deletions
-5
View File
@@ -223,14 +223,9 @@ const _executeSubscription = (sub: Subscription) => {
const executor = ctx.net.getExecutor(relays)
const subs: {unsubscribe: () => void}[] = []
const completedRelays = new Set()
const events: TrustedEvent[] = []
// Hook up our events
emitter.on(SubscriptionEvent.Event, (url: string, event: TrustedEvent) => {
events.push(event)
})
emitter.on(SubscriptionEvent.Eose, (url: string) => {
completedRelays.add(url)