Skip to content

Commit 5d4528d

Browse files
committed
fix the issue where we compare the SEED.length to undefined
fix input-output-hk#39
1 parent 760d30c commit 5d4528d

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

js/HdWallet.js

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,10 @@ import RustModule from './RustModule';
33
import { newArray, newArray0, copyArray } from './utils/arrays';
44
import { apply } from './utils/functions';
55

6-
const SEED_SIZE = 32;
7-
const XPRV_SIZE = 96;
8-
const XPUB_SIZE = 64;
9-
const SIGNATURE_SIZE = 64;
6+
export const SEED_SIZE = 32;
7+
export const XPRV_SIZE = 96;
8+
export const XPUB_SIZE = 64;
9+
export const SIGNATURE_SIZE = 64;
1010

1111

1212
/**
@@ -167,5 +167,9 @@ export default {
167167
derivePublic: apply(derivePublic, RustModule),
168168
sign: apply(sign, RustModule),
169169
publicKeyToAddress: apply(publicKeyToAddress, RustModule),
170-
addressGetPayload: apply(addressGetPayload, RustModule)
170+
addressGetPayload: apply(addressGetPayload, RustModule),
171+
SEED_SIZE: SEED_SIZE,
172+
XPRV_SIZE: XPRV_SIZE,
173+
XPUB_SIZE: XPUB_SIZE,
174+
SIGNATURE_SIZE: SIGNATURE_SIZE,
171175
};

0 commit comments

Comments
 (0)