diff --git a/src/js/services/profileService.js b/src/js/services/profileService.js index e3238db97..f14acff19 100644 --- a/src/js/services/profileService.js +++ b/src/js/services/profileService.js @@ -62,23 +62,24 @@ angular.module('copayApp.services') }); }; - root._getBaseURL = function(walletId) { - var config = configService.getSync(); - var defaults = configService.getDefaults(); - - return ((config.bwsFor && config.bwsFor[walletId]) || defaults.bws.url); - } - root.setWalletClient = function(credentials) { if (root.walletClients[credentials.walletId] && root.walletClients[credentials.walletId].started) { return; } + + var getBaseURL = function(walletId) { + var config = configService.getSync(); + var defaults = configService.getDefaults(); + + return ((config.bwsFor && config.bwsFor[walletId]) || defaults.bws.url); + }; + $log.debug('Importing wallet:' + credentials.walletId); var skipKeyValidation = root.profile.checked[credentials.walletId] == platformInfo.ua; var client = bwcService.getClient(JSON.stringify(credentials), { - baseurl: root._getBaseURL(credentials.walletId), + baseurl: getBaseURL(credentials.walletId), skipKeyValidation: skipKeyValidation, }); root.walletClients[credentials.walletId] = client; diff --git a/src/js/services/storageService.js b/src/js/services/storageService.js index 4b9b91b33..d80a0f78d 100644 --- a/src/js/services/storageService.js +++ b/src/js/services/storageService.js @@ -113,7 +113,6 @@ angular.module('copayApp.services') }; root.storeProfile = function(profile, cb) { -console.log('[storageService.js.115:storeProfile:]',profile); //TODO encryptOnMobile(profile.toObj(), function(err, x) { storage.set('profile', x, cb); });