Post review fixes

This commit is contained in:
Zoe Faltibà 2022-07-21 17:00:21 +02:00
parent 5f12900c6d
commit a3ae4635eb
No known key found for this signature in database
GPG Key ID: 05CB7E816D1A93A8

View File

@ -20,7 +20,7 @@ use bdk::{
Wallet as BdkWallet,
};
use std::collections::HashSet;
use std::convert::{From, TryFrom, TryInto};
use std::convert::{From, TryFrom};
use std::fmt;
use std::ops::Deref;
use std::str::FromStr;
@ -552,7 +552,7 @@ impl TxBuilder {
tx_builder.change_policy(self.change_policy);
if !self.utxos.is_empty() {
let bdk_utxos: Vec<BdkOutPoint> = self.utxos.iter().map(BdkOutPoint::from).collect();
let utxos: &[BdkOutPoint] = bdk_utxos[..].try_into().unwrap();
let utxos: &[BdkOutPoint] = &bdk_utxos;
tx_builder.add_utxos(utxos)?;
}
if !self.unspendable.is_empty() {