mirror of
https://github.com/arnaucube/arbo.git
synced 2026-01-09 07:21:28 +01:00
Merge pull request #11 from vocdoni/fix/incNLeafs
Fix: Use GetNLeafsWithTx in incNLeafs
This commit is contained in:
2
tree.go
2
tree.go
@@ -807,7 +807,7 @@ func CheckProof(hashFunc HashFunction, k, v, root, packedSiblings []byte) (bool,
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (t *Tree) incNLeafs(wTx db.WriteTx, nLeafs int) error {
|
func (t *Tree) incNLeafs(wTx db.WriteTx, nLeafs int) error {
|
||||||
oldNLeafs, err := t.GetNLeafs()
|
oldNLeafs, err := t.GetNLeafsWithTx(wTx)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user