From: Esraa Jbara Date: Tue, 9 Nov 2021 08:56:59 +0000 (+0200) Subject: change send amount to half balance X-Git-Url: http://internal-gitweb-vhost/script/%22https:/struct.CommandStringError.html?a=commitdiff_plain;h=db426b036bb85acd01ac8390a47bc1f73414c25e;p=bitcoindevkit.org change send amount to half balance --- diff --git a/docs/_blog/hello-world.md b/docs/_blog/hello-world.md index 197b727552..772dcc74bd 100644 --- a/docs/_blog/hello-world.md +++ b/docs/_blog/hello-world.md @@ -151,7 +151,7 @@ let faucet_address = Address::from_str("mkHS9ne12qx9pS9VojpwU5xtRd4T7X7ZUt")?; let mut tx_builder = wallet.build_tx(); tx_builder - .add_recipient(faucet_address.script_pubkey(), 0_900) + .add_recipient(faucet_address.script_pubkey(), balance / 2) .fee_rate(FeeRate::from_sat_per_vb(5.0)) .enable_rbf(); let (mut psbt, tx_details) = tx_builder.finish()?;