From 42c726f485156ad8786f088ad1904023b4c4313e Mon Sep 17 00:00:00 2001 From: Leonardo Lima Date: Thu, 6 Jun 2024 15:09:51 -0300 Subject: [PATCH] fix(examples): use `compute_txid()` instead of `txid` --- example-crates/wallet_electrum/src/main.rs | 2 +- example-crates/wallet_esplora_async/src/main.rs | 2 +- example-crates/wallet_esplora_blocking/src/main.rs | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/example-crates/wallet_electrum/src/main.rs b/example-crates/wallet_electrum/src/main.rs index e6c01c20be..d8dbc458f7 100644 --- a/example-crates/wallet_electrum/src/main.rs +++ b/example-crates/wallet_electrum/src/main.rs @@ -94,7 +94,7 @@ fn main() -> Result<(), anyhow::Error> { let tx = psbt.extract_tx()?; client.transaction_broadcast(&tx)?; - println!("Tx broadcasted! Txid: {}", tx.txid()); + println!("Tx broadcasted! Txid: {}", tx.compute_txid()); Ok(()) } diff --git a/example-crates/wallet_esplora_async/src/main.rs b/example-crates/wallet_esplora_async/src/main.rs index f46779b3c1..6510c5660e 100644 --- a/example-crates/wallet_esplora_async/src/main.rs +++ b/example-crates/wallet_esplora_async/src/main.rs @@ -103,7 +103,7 @@ async fn main() -> Result<(), anyhow::Error> { let tx = psbt.extract_tx()?; client.broadcast(&tx).await?; - println!("Tx broadcasted! Txid: {}", tx.txid()); + println!("Tx broadcasted! Txid: {}", tx.compute_txid()); Ok(()) } diff --git a/example-crates/wallet_esplora_blocking/src/main.rs b/example-crates/wallet_esplora_blocking/src/main.rs index 92caca2c9b..5ade6804e0 100644 --- a/example-crates/wallet_esplora_blocking/src/main.rs +++ b/example-crates/wallet_esplora_blocking/src/main.rs @@ -80,7 +80,7 @@ fn main() -> Result<(), anyhow::Error> { let tx = psbt.extract_tx()?; client.broadcast(&tx)?; - println!("Tx broadcasted! Txid: {}", tx.txid()); + println!("Tx broadcasted! Txid: {}", tx.compute_txid()); Ok(()) }