Add 'recover' option to grin wallet init (#2330)

* Only update outputs with unconfirmed transactions outstanding

* add further check for Unspent output that have been spent to check_repair

* rename  to

* make updating all outputs optional API parameter. do full update before a wallet check, remove unspent->spent check from check process

* rustfmt

* typo

* add recover from phrase option to init

* rustfmt

* don't panic if recover is cancelled, grin-wallet.toml is created but wallet_data dir doesn't yet exits

* rustfmt
This commit is contained in:
Yeastplume
2019-01-10 12:06:12 +00:00
committed by GitHub
parent 4191b15410
commit cd9a539288
11 changed files with 53 additions and 12 deletions
+1 -1
View File
@@ -160,7 +160,7 @@ where
{
let mut wallet_config = WalletConfig::default();
wallet_config.data_file_dir = String::from(dir);
let _ = WalletSeed::init_file(&wallet_config, 32, "");
let _ = WalletSeed::init_file(&wallet_config, 32, None, "");
let mut wallet = LMDBBackend::new(wallet_config.clone(), "", n_client)
.unwrap_or_else(|e| panic!("Error creating wallet: {:?} Config: {:?}", e, wallet_config));
wallet.open_with_credentials().unwrap_or_else(|e| {