|
13 | 13 | use std::path::PathBuf; |
14 | 14 | use std::str::FromStr; |
15 | 15 |
|
| 16 | +use crate::commands::WalletOpts; |
16 | 17 | #[cfg(any( |
17 | 18 | feature = "electrum", |
18 | 19 | feature = "esplora", |
19 | 20 | feature = "compact_filters", |
20 | 21 | feature = "rpc" |
21 | 22 | ))] |
22 | | -use crate::backend::Backend; |
23 | | -use crate::commands::WalletOpts; |
| 23 | +use crate::nodes::Nodes; |
24 | 24 | use bdk::bitcoin::secp256k1::Secp256k1; |
25 | 25 | use bdk::bitcoin::{Address, Network, OutPoint, Script}; |
26 | 26 | #[cfg(feature = "compact_filters")] |
@@ -199,12 +199,12 @@ pub(crate) fn open_database(wallet_opts: &WalletOpts) -> Result<AnyDatabase, Err |
199 | 199 | pub(crate) fn new_blockchain( |
200 | 200 | _network: Network, |
201 | 201 | wallet_opts: &WalletOpts, |
202 | | - _backend: &Backend, |
| 202 | + _backend: &Nodes, |
203 | 203 | ) -> Result<AnyBlockchain, Error> { |
204 | 204 | #[cfg(feature = "electrum")] |
205 | 205 | let config = { |
206 | 206 | let url = match _backend { |
207 | | - Backend::Electrum { electrum_url } => electrum_url.to_owned(), |
| 207 | + Nodes::Electrum { electrum_url } => electrum_url.to_owned(), |
208 | 208 | _ => wallet_opts.electrum_opts.server.clone(), |
209 | 209 | }; |
210 | 210 |
|
@@ -254,7 +254,7 @@ pub(crate) fn new_blockchain( |
254 | 254 | #[cfg(feature = "rpc")] |
255 | 255 | let config: AnyBlockchainConfig = { |
256 | 256 | let (url, auth) = match _backend { |
257 | | - Backend::Bitcoin { rpc_url, rpc_auth } => ( |
| 257 | + Nodes::Bitcoin { rpc_url, rpc_auth } => ( |
258 | 258 | rpc_url, |
259 | 259 | Auth::Cookie { |
260 | 260 | file: rpc_auth.into(), |
|
0 commit comments