only needsBackup parameter in function callback
This commit is contained in:
parent
309e0dfc1a
commit
12b3808ade
1 changed files with 14 additions and 12 deletions
|
|
@ -41,7 +41,7 @@ angular.module('copayApp.services')
|
||||||
root.setBackupFlag = function(walletId) {
|
root.setBackupFlag = function(walletId) {
|
||||||
storageService.setBackupFlag(walletId, function(err) {
|
storageService.setBackupFlag(walletId, function(err) {
|
||||||
if (err) $log.error(err);
|
if (err) $log.error(err);
|
||||||
$log.debug('Backup stored');
|
$log.debug('Backup flag stored');
|
||||||
root.wallet[walletId].needsBackup = false;
|
root.wallet[walletId].needsBackup = false;
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
@ -74,22 +74,24 @@ angular.module('copayApp.services')
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
_needsBackup(wallet, function(val) {
|
// INIT WALLET VIEWMODEL
|
||||||
// INIT WALLET VIEWMODEL
|
wallet.id = walletId;
|
||||||
wallet.id = walletId;
|
wallet.started = true;
|
||||||
wallet.started = true;
|
wallet.doNotVerifyPayPro = isChromeApp;
|
||||||
wallet.doNotVerifyPayPro = isChromeApp;
|
wallet.network = wallet.credentials.network;
|
||||||
wallet.network = wallet.credentials.network;
|
wallet.copayerId = wallet.credentials.copayerId;
|
||||||
wallet.copayerId = wallet.credentials.copayerId;
|
wallet.m = wallet.credentials.m;
|
||||||
wallet.m = wallet.credentials.m;
|
wallet.n = wallet.credentials.n;
|
||||||
wallet.n = wallet.credentials.n;
|
|
||||||
wallet.needsBackup = val;
|
|
||||||
|
|
||||||
root.updateWalletSettings(wallet);
|
root.updateWalletSettings(wallet);
|
||||||
root.wallet[walletId] = wallet;
|
root.wallet[walletId] = wallet;
|
||||||
|
|
||||||
|
_needsBackup(wallet, function(val) {
|
||||||
|
wallet.needsBackup = val;
|
||||||
});
|
});
|
||||||
|
|
||||||
wallet.removeAllListeners();
|
wallet.removeAllListeners();
|
||||||
|
|
||||||
wallet.on('report', function(n) {
|
wallet.on('report', function(n) {
|
||||||
$log.info('BWC Report:' + n);
|
$log.info('BWC Report:' + n);
|
||||||
});
|
});
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue