@cityofzion/bs-ethereum 2.8.3 → 2.8.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -104,10 +104,10 @@ class BSEthereum {
104
104
  }
105
105
  generateAccountFromMnemonic(mnemonic, index) {
106
106
  const bip44Path = this.bip44DerivationPath.replace('?', index.toString());
107
- const wallet = ethers_1.ethers.Wallet.fromMnemonic(Array.isArray(mnemonic) ? mnemonic.join(' ') : mnemonic, bip44Path);
107
+ const hd = ethers_1.ethers.utils.HDNode.fromMnemonic(Array.isArray(mnemonic) ? mnemonic.join(' ') : mnemonic).derivePath(bip44Path);
108
108
  return {
109
- address: wallet.address,
110
- key: wallet.privateKey,
109
+ address: hd.address,
110
+ key: hd.privateKey,
111
111
  type: 'privateKey',
112
112
  bip44Path,
113
113
  blockchain: this.name,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cityofzion/bs-ethereum",
3
- "version": "2.8.3",
3
+ "version": "2.8.4",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "repository": "https://github.com/CityOfZion/blockchain-services",