Skip to content

Commit

Permalink
fix: set hahser for persistent-merkle-tree inside @chainsafe/ssz
Browse files Browse the repository at this point in the history
  • Loading branch information
twoeths committed Oct 12, 2023
1 parent 3596ab8 commit a0ed2cb
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions packages/cli/src/applyPreset.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,13 @@ import {hasher} from "@chainsafe/persistent-merkle-tree/lib/hasher/as-sha256.js"
// eslint-disable-next-line no-restricted-imports, import/no-extraneous-dependencies
import {setHasher} from "@chainsafe/persistent-merkle-tree/lib/hasher/index.js";

// eslint-disable-next-line no-restricted-imports, import/no-extraneous-dependencies
import {setHasher as setHasherSsz} from "@chainsafe/ssz/node_modules/@chainsafe/persistent-merkle-tree/lib/hasher/index.js";

// without setting this first, persistent-merkle-tree will use noble instead
// there are 2 instances of persistent-merkle-tree so we need to set hasher for all of them
setHasher(hasher);
setHasherSsz(hasher);

//
// ## Rationale
Expand Down

0 comments on commit a0ed2cb

Please sign in to comment.