Skip to content

Commit b924a79

Browse files
committed
rust: send_transaction: update txid
1 parent 2f88ec9 commit b924a79

File tree

1 file changed

+4
-1
lines changed
  • subprojects/gdk_rust/gdk_electrum/src

1 file changed

+4
-1
lines changed

subprojects/gdk_rust/gdk_electrum/src/lib.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -977,7 +977,10 @@ impl ElectrumSession {
977977
if let Some(memo) = tx.create_transaction.as_ref().and_then(|o| o.memo.as_ref()) {
978978
self.get_wallet()?.store.write()?.insert_memo(txid.into(), memo)?;
979979
}
980-
Ok(tx.clone())
980+
let mut tx = tx.clone();
981+
// If sign transaction happens externally txid might not have been updated
982+
tx.txid = txid.to_string();
983+
Ok(tx)
981984
}
982985

983986
pub fn broadcast_transaction(&mut self, tx_hex: &str) -> Result<String, Error> {

0 commit comments

Comments
 (0)