Initialize thunk status
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import {Writable, Readable, writable, derived, get} from "svelte/store"
|
||||
import {Deferred, TaskQueue, dissoc, identity, uniq, defer, sleep, assoc} from "@welshman/lib"
|
||||
import {Deferred, fromPairs, TaskQueue, dissoc, identity, uniq, defer, sleep, assoc} from "@welshman/lib"
|
||||
import {stamp, own, hash} from "@welshman/signer"
|
||||
import {
|
||||
TrustedEvent,
|
||||
@@ -222,6 +222,14 @@ export const thunkQueue = new TaskQueue<Thunk>({
|
||||
return
|
||||
}
|
||||
|
||||
// Update status to pending
|
||||
thunk.status.set(
|
||||
fromPairs(
|
||||
thunk.request.relays
|
||||
.map(url => [url, {status: PublishStatus.Pending, message: "Sending your message..."}])
|
||||
)
|
||||
)
|
||||
|
||||
// Send it off
|
||||
const pub = new MultiPublish({
|
||||
event: signedEvent,
|
||||
|
||||
Reference in New Issue
Block a user