fix preDerivation
This commit is contained in:
parent
619e743af0
commit
c4964c1929
2 changed files with 2 additions and 2 deletions
|
|
@ -100,7 +100,7 @@ angular.module('copayApp.services')
|
||||||
|
|
||||||
default:
|
default:
|
||||||
$log.warn('Unknown error type:', err.code);
|
$log.warn('Unknown error type:', err.code);
|
||||||
body = err.code + ':' + err.message ;
|
body = err.message || err.code;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -170,7 +170,7 @@ angular.module('copayApp.services')
|
||||||
var walletClient = bwcService.getClient();
|
var walletClient = bwcService.getClient();
|
||||||
var network = opts.networkName || 'livenet';
|
var network = opts.networkName || 'livenet';
|
||||||
|
|
||||||
if (opts.mnemonic && opts.mnemonic.indexOf('m/' != 0)) {
|
if (opts.mnemonic && opts.mnemonic.indexOf('m/') == 0) {
|
||||||
var xPrivKey = root._preDerivation(opts.mnemonic, network);
|
var xPrivKey = root._preDerivation(opts.mnemonic, network);
|
||||||
if (!xPrivKey)
|
if (!xPrivKey)
|
||||||
return bwsError.cb('Bad derivation', gettext('Could not import'), cb);
|
return bwsError.cb('Bad derivation', gettext('Could not import'), cb);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue