@xyo-network/bip39 2.84.5 → 2.84.7

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.
@@ -18539,10 +18539,10 @@ var calcChecksum = (entropy) => {
18539
18539
  function getCoder(wordlist10) {
18540
18540
  if (!Array.isArray(wordlist10) || wordlist10.length !== 2048 || typeof wordlist10[0] !== "string")
18541
18541
  throw new Error("Worlist: expected array of 2048 strings");
18542
- wordlist10.forEach((i) => {
18542
+ for (const i of wordlist10) {
18543
18543
  if (typeof i !== "string")
18544
18544
  throw new Error(`Wordlist: non-string element: ${i}`);
18545
- });
18545
+ }
18546
18546
  return import_base.utils.chain(import_base.utils.checksum(1, calcChecksum), import_base.utils.radix2(11, true), import_base.utils.alphabet(wordlist10));
18547
18547
  }
18548
18548
  function mnemonicToEntropy(mnemonic, wordlist10) {
@@ -18559,7 +18559,7 @@ function entropyToMnemonic(entropy, wordlist10) {
18559
18559
  function validateMnemonic(mnemonic, wordlist10) {
18560
18560
  try {
18561
18561
  mnemonicToEntropy(mnemonic, wordlist10);
18562
- } catch (e) {
18562
+ } catch {
18563
18563
  return false;
18564
18564
  }
18565
18565
  return true;