Skip to content
This repository has been archived by the owner on Feb 27, 2023. It is now read-only.

Commit

Permalink
"a new root" -> "the new root"
Browse files Browse the repository at this point in the history
  • Loading branch information
musalbas committed Jan 13, 2021
1 parent bbaeac8 commit 870d9a9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions smt.go
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ func (smt *SparseMerkleTree) Update(key []byte, value []byte) ([]byte, error) {
return newRoot, err
}

// Delete deletes a value from tree. It returns a new root of the tree.
// Delete deletes a value from tree. It returns the new root of the tree.
func (smt *SparseMerkleTree) Delete(key []byte) ([]byte, error) {
return smt.Update(key, defaultValue)
}
Expand Down Expand Up @@ -172,7 +172,7 @@ func (smt *SparseMerkleTree) UpdateForRoot(key []byte, value []byte, root []byte
return newRoot, err
}

// Delete deletes a value from tree at a specific root. It returns a new root of the tree.
// Delete deletes a value from tree at a specific root. It returns the new root of the tree.
func (smt *SparseMerkleTree) DeleteForRoot(key, root []byte) ([]byte, error) {
return smt.UpdateForRoot(key, defaultValue, root)
}
Expand Down

0 comments on commit 870d9a9

Please sign in to comment.