mirror of
https://github.com/Qortal/altcoinj.git
synced 2025-11-16 12:27:24 +00:00
Updated WalletAppKit to allow autosave configuration override
This commit is contained in:
committed by
Andreas Schildbach
parent
fae82e0f2b
commit
1878f5b9fc
@@ -376,11 +376,17 @@ public class WalletAppKit extends AbstractIdleService {
|
||||
wallet = loadWallet(false);
|
||||
}
|
||||
|
||||
if (useAutoSave) wallet.autosaveToFile(vWalletFile, 5, TimeUnit.SECONDS, null);
|
||||
if (useAutoSave) {
|
||||
this.setupAutoSave(wallet);
|
||||
}
|
||||
|
||||
return wallet;
|
||||
}
|
||||
|
||||
protected void setupAutoSave(Wallet wallet) {
|
||||
wallet.autosaveToFile(vWalletFile, 5, TimeUnit.SECONDS, null);
|
||||
}
|
||||
|
||||
private Wallet loadWallet(boolean shouldReplayWallet) throws Exception {
|
||||
Wallet wallet;
|
||||
FileInputStream walletStream = new FileInputStream(vWalletFile);
|
||||
|
||||
Reference in New Issue
Block a user