From b6979a3432f6f93659ab8b6abd2501ba70de9c44 Mon Sep 17 00:00:00 2001 From: Andrey Shovkoplyas Date: Wed, 6 Nov 2019 14:59:00 +0100 Subject: [PATCH] buffer --- package-lock.json | 19 +++++++++++++++++++ package.json | 1 + src/index.js | 1 + 3 files changed, 21 insertions(+) diff --git a/package-lock.json b/package-lock.json index 8c725b8..9031361 100644 --- a/package-lock.json +++ b/package-lock.json @@ -214,6 +214,11 @@ "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=", "dev": true }, + "base64-js": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.3.1.tgz", + "integrity": "sha512-mLQ4i2QO1ytvGWFWmcngKO//JXAQueZvwEKtjgQFM4jIK0kU+ytMfplL8j+n5mspOfjHwoAg+9yhb7BwAHm36g==" + }, "brace-expansion": { "version": "1.1.11", "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", @@ -224,6 +229,15 @@ "concat-map": "0.0.1" } }, + "buffer": { + "version": "5.4.3", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.4.3.tgz", + "integrity": "sha512-zvj65TkFeIt3i6aj5bIvJDzjjQQGs4o/sNoezg1F1kYap9Nu2jcUdpwzRSJTHMMzG0H7bZkn4rNQpImhuxWX2A==", + "requires": { + "base64-js": "^1.0.2", + "ieee754": "^1.1.4" + } + }, "builtin-modules": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/builtin-modules/-/builtin-modules-1.1.1.tgz", @@ -678,6 +692,11 @@ "safer-buffer": ">= 2.1.2 < 3" } }, + "ieee754": { + "version": "1.1.13", + "resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.1.13.tgz", + "integrity": "sha512-4vf7I2LYV/HaWerSo3XmlMkp5eZ83i+/CDluXi/IGTs/O1sejBNhTtnxzmRZfvOUqj7lZjqHkeTvpgSFDlWZTg==" + }, "imurmurhash": { "version": "0.1.4", "resolved": "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz", diff --git a/package.json b/package.json index 1c523a4..c9600f4 100644 --- a/package.json +++ b/package.json @@ -36,6 +36,7 @@ ], "dependencies": { "@types/node": "11.11.6", + "buffer": "^5.4.3", "create-hash": "^1.1.0", "stream": "^0.0.2" }, diff --git a/src/index.js b/src/index.js index cc61825..f932db7 100644 --- a/src/index.js +++ b/src/index.js @@ -1,6 +1,7 @@ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); const createHash = require("create-hash"); +const Buffer = require('buffer/').Buffer const INVALID_MNEMONIC = 'Invalid mnemonic'; const INVALID_ENTROPY = 'Invalid entropy'; const INVALID_CHECKSUM = 'Invalid mnemonic checksum';