@shapeshiftoss/hdwallet-core
Advanced tools
Comparing version 1.15.2 to 1.15.3-alpha.0
@@ -0,1 +1,2 @@ | ||
/// <reference types="node" /> | ||
import * as eventemitter2 from "eventemitter2"; | ||
@@ -49,3 +50,5 @@ import * as Rx from "rxjs"; | ||
export declare function untouchable(message: string): any; | ||
export declare function checkBufferConcat(): boolean; | ||
export declare function compatibleBufferConcat(list: Uint8Array[]): Buffer; | ||
export {}; | ||
//# sourceMappingURL=utils.d.ts.map |
@@ -22,3 +22,3 @@ "use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.untouchable = exports.mustBeDefined = exports.toArrayBuffer = exports.relativePath = exports.hardenedPath = exports.satsFromStr = exports.slip44ByCoin = exports.base64toHEX = exports.stripHexPrefixAndLower = exports.stripHexPrefix = exports.takeFirstOfManyEvents = exports.bip32Like = exports.addressNListToBIP32 = exports.bip32ToAddressNList = exports.arrayify = exports.toHexString = exports.fromHexString = exports.isArray = exports.LONG_TIMEOUT = exports.DEFAULT_TIMEOUT = void 0; | ||
exports.compatibleBufferConcat = exports.checkBufferConcat = exports.untouchable = exports.mustBeDefined = exports.toArrayBuffer = exports.relativePath = exports.hardenedPath = exports.satsFromStr = exports.slip44ByCoin = exports.base64toHEX = exports.stripHexPrefixAndLower = exports.stripHexPrefix = exports.takeFirstOfManyEvents = exports.bip32Like = exports.addressNListToBIP32 = exports.bip32ToAddressNList = exports.arrayify = exports.toHexString = exports.fromHexString = exports.isArray = exports.LONG_TIMEOUT = exports.DEFAULT_TIMEOUT = void 0; | ||
const Rx = __importStar(require("rxjs")); | ||
@@ -200,2 +200,24 @@ const RxOp = __importStar(require("rxjs/operators")); | ||
exports.untouchable = untouchable; | ||
// Webpack 4's Buffer.concat() polyfill requires Buffer[] instead of Uint8Array[]. This is a | ||
// kludgy compatibility hack until everything gets bumped to Webpack 5. | ||
let needCompatibleBufferConcat = undefined; | ||
function checkBufferConcat() { | ||
if (needCompatibleBufferConcat === undefined) { | ||
try { | ||
Buffer.concat([new Uint8Array()]); | ||
needCompatibleBufferConcat = false; | ||
} | ||
catch (_a) { | ||
needCompatibleBufferConcat = true; | ||
} | ||
} | ||
return needCompatibleBufferConcat; | ||
} | ||
exports.checkBufferConcat = checkBufferConcat; | ||
function compatibleBufferConcat(list) { | ||
if (!checkBufferConcat()) | ||
return Buffer.concat(list); | ||
return Buffer.concat(list.map(x => Buffer.isBuffer(x) ? x : Buffer.from(x))); | ||
} | ||
exports.compatibleBufferConcat = compatibleBufferConcat; | ||
//# sourceMappingURL=utils.js.map |
{ | ||
"name": "@shapeshiftoss/hdwallet-core", | ||
"version": "1.15.2", | ||
"version": "1.15.3-alpha.0", | ||
"license": "MIT", | ||
@@ -33,3 +33,3 @@ "publishConfig": { | ||
}, | ||
"gitHead": "cfce2b9aab2139cfe060abb72e3c67b8f3e335e8" | ||
"gitHead": "6ce0a761f5851245186137726c9f8a48e63f1f46" | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Deprecated
MaintenanceThe maintainer of the package marked it as deprecated. This could indicate that a single version should not be used, or that the package is no longer maintained and any new vulnerabilities will not be fixed.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
182340
2958
1
2