Make generate_remote_keypair more generic for potential other remote-wallets (#8274)

This commit is contained in:
Tyera Eulberg
2020-02-14 09:38:35 -07:00
committed by GitHub
parent 5b4ecb01ca
commit c350543b46
3 changed files with 32 additions and 29 deletions

View File

@@ -1,9 +1,5 @@
use crate::{
remote_keypair::RemoteKeypair,
remote_wallet::{
initialize_wallet_manager, DerivationPath, RemoteWallet, RemoteWalletError,
RemoteWalletInfo, RemoteWalletType,
},
use crate::remote_wallet::{
initialize_wallet_manager, DerivationPath, RemoteWallet, RemoteWalletError, RemoteWalletInfo,
};
use dialoguer::{theme::ColorfulTheme, Select};
use log::*;
@@ -369,13 +365,3 @@ pub fn get_ledger_from_info(
};
wallet_manager.get_ledger(&wallet_base_pubkey)
}
pub fn generate_remote_keypair(
ledger: Arc<LedgerWallet>,
derivation_path: DerivationPath,
) -> RemoteKeypair {
RemoteKeypair {
wallet_type: RemoteWalletType::Ledger(ledger),
derivation_path,
}
}