Comparing version 0.4.1 to 0.4.2
@@ -47,3 +47,3 @@ /* | ||
// skip the root | ||
if (text.startsWith('m/')) { | ||
if (/^m\//i.test(text)) { | ||
text = text.slice(2) | ||
@@ -50,0 +50,0 @@ } else if (reqRoot) { |
{ | ||
"name": "bippath", | ||
"version": "0.4.1", | ||
"version": "0.4.2", | ||
"description": "Bitcoin BIP32 ('HD Wallet') path helpers.", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -27,3 +27,3 @@ # BIPPath | ||
Binary path arrays contain each node as a separate number, where hardened nodes are marked by setting the 32th bit: `m/44'/1/1/0` corresponds to `[ 44 | 0x80000000, 1, 1, 0 ]` | ||
Binary path arrays contain each node as a separate number, where hardened nodes are marked by setting the 32th bit: `m/44'/1/1/0` corresponds to `[ 0x8000002c, 1, 1, 0 ]` | ||
@@ -36,3 +36,3 @@ | ||
bippath.fromPathArray([44 | 0x80000000, 1, 1, 0]).toString() // m/44'/1/1/0 | ||
bippath.fromPathArray([0x8000002c, 1, 1, 0]).toString() // m/44'/1/1/0 | ||
@@ -43,3 +43,3 @@ bippath.fromString("m/44'/0'/0'").toString(false, true) // m/44h/0h/0h | ||
bippath.fromString("m/44'/0'/0'").toPathArray() // [ 0x80000044, 0x80000000, 0x80000000 ] | ||
bippath.fromString("m/44'/0'/0'").toPathArray() // [ 0x8000002c, 0x80000000, 0x80000000 ] | ||
``` |
10734