Fix Memo post broadcast to use wallet public sendOpReturn signature

By specifier.
This commit is contained in:
Chris Troutner
2026-08-25 18:03:09 -07:00
parent 122524ca18
commit 695292ccd2
+6 -9
View File
@@ -49,16 +49,13 @@ class MemoPost {
throw new Error('Memo post requires a wallet.') throw new Error('Memo post requires a wallet.')
} }
// Spendable outputs used to pay the transaction fee. // Refresh the wallet's spendable UTXO store so the broadcast has inputs.
const bchUtxos = await this.wallet.getUtxos() await this.wallet.getUtxos()
// Broadcast the OP_RETURN transaction with the Memo post prefix. // The wallet's public sendOpReturn(msg, prefix) resolves walletInfo and
const txid = await this.wallet.sendOpReturn( // its own spendable UTXOs internally, so only the message and Memo post
this.wallet.walletInfo, // prefix are passed here.
bchUtxos, const txid = await this.wallet.sendOpReturn(message, MEMO_POST_PREFIX)
message,
MEMO_POST_PREFIX
)
// Reflect the new post in the feed once broadcast succeeds. // Reflect the new post in the feed once broadcast succeeds.
this._reflectPost(txid, message) this._reflectPost(txid, message)