Skip to content

Commit

Permalink
fix: don't create settings each time a key is calculated (#53)
Browse files Browse the repository at this point in the history
  • Loading branch information
gballet authored Jan 10, 2022
1 parent c87a6d9 commit 99f3c92
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions trie/utils/verkle.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ package utils

import (
"github.com/crate-crypto/go-ipa/bandersnatch/fr"
"github.com/crate-crypto/go-ipa/ipa"
"github.com/gballet/go-verkle"

"github.com/holiman/uint256"
Expand Down Expand Up @@ -55,7 +54,7 @@ func GetTreeKey(address []byte, treeIndex *uint256.Int, subIndex byte) []byte {
verkle.CopyFr(&poly[i], &verkle.FrZero)
}

ret := ipa.NewIPASettings().Commit(poly[:])
ret := verkle.GetConfig().CommitToPoly(poly[:], 0)
retb := ret.Bytes()
return retb[:]

Expand Down

0 comments on commit 99f3c92

Please sign in to comment.