Skip to content

Commit f392bd3

Browse files
committed
fix linter issues
1 parent 660622a commit f392bd3

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

proof_ipa.go

+2-1
Original file line numberDiff line numberDiff line change
@@ -433,7 +433,7 @@ func PreStateTreeFromProof(proof *Proof, rootC *Point) (VerkleNode, error) {
433433
return root, nil
434434
}
435435

436-
func PostStateTreeFromProof(preroot VerkleNode, statediff StateDiff, rootC *Point) (VerkleNode, error) {
436+
func PostStateTreeFromProof(preroot VerkleNode, statediff StateDiff) (VerkleNode, error) {
437437
postroot := preroot.Copy()
438438
for _, stemstatediff := range statediff {
439439
var (
@@ -458,6 +458,7 @@ func PostStateTreeFromProof(preroot VerkleNode, statediff StateDiff, rootC *Poin
458458
}
459459
}
460460
}
461+
postroot.Commit()
461462

462463
return postroot, nil
463464
}

proof_test.go

+4
Original file line numberDiff line numberDiff line change
@@ -729,6 +729,8 @@ func TestStatelessDeserializeDepth2(t *testing.T) {
729729
}
730730

731731
func TestProofVerificationWithPostState(t *testing.T) {
732+
t.Parallel()
733+
732734
testlist := []struct {
733735
name string
734736
keys, values, keystoprove, updatekeys, updatevalues [][]byte
@@ -762,6 +764,8 @@ func TestProofVerificationWithPostState(t *testing.T) {
762764
},
763765
}
764766
for _, data := range testlist {
767+
data := data // make linter happy by not capturing the loop variable
768+
765769
t.Run(fmt.Sprintf("verification_with_post_state/%s", data.name), func(t *testing.T) {
766770
t.Parallel()
767771

0 commit comments

Comments
 (0)