Splitting key load / wallet creation so we can use keys in esplora client

This commit is contained in:
Dave Hrycyszyn
2024-06-24 17:20:52 +01:00
parent 5c03a77e56
commit 117915bded
4 changed files with 51 additions and 24 deletions

View File

@@ -42,7 +42,8 @@ async fn setup(name: &String) -> SideNode {
// First, load up the keys and create a bft-crdt
let side_dir = utils::home(name);
let bft_crdt_keys = keys::bft_crdt::load_from_file(&side_dir);
let bitcoin_wallet = keys::bitcoin::load_from_file(&side_dir).unwrap();
let bitcoin_keys = keys::bitcoin::load_from_file(&side_dir).unwrap();
let bitcoin_wallet = clients::btc_electrum_client::create_wallet(bitcoin_keys).unwrap();
let crdt = BaseCrdt::<TransactionList>::new(&bft_crdt_keys);
// Channels for internal communication, and a tokio task for stdin input