Add relay package

This commit is contained in:
Jon Staab
2025-03-31 10:16:28 -07:00
parent 5245993d4e
commit cfd2e3aac7
21 changed files with 234 additions and 106 deletions
+2 -2
View File
@@ -18,7 +18,7 @@ import {
isUnwrappedEvent,
isSignedEvent,
} from "@welshman/util"
import {publish, PublishStatus} from "@welshman/net"
import {MultiPublish, PublishStatus} from "@welshman/net"
import {repository, tracker} from "./core.js"
import {pubkey, getSession, getSigner} from "./session.js"
@@ -225,7 +225,7 @@ thunkWorker.addGlobalHandler((thunk: Thunk) => {
}
// Send it off
const pub = publish({event: signedEvent, relays: thunk.request.relays})
const pub = new MultiPublish({event: signedEvent, relays: thunk.request.relays})
// Copy the signature over since we had deferred it
const savedEvent = repository.getEvent(signedEvent.id) as SignedEvent