Skip to content

Commit

Permalink
chore: self-review improvements
Browse files Browse the repository at this point in the history
Signed-off-by: Bryan White <[email protected]>
  • Loading branch information
bryanchriswhite authored Jul 16, 2024
1 parent 96df23c commit e499540
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions root.go
Original file line number Diff line number Diff line change
Expand Up @@ -56,13 +56,13 @@ func (root MerkleSumRoot) DigestSize() int {
return len(root) - countSizeBytes - sumSizeBytes
}

// HasDigestSize returns true if the root hash (digest) length is the same as
// HasDigestSize returns true if the root digest size is the same as
// that of the size of the given hasher.
func (root MerkleSumRoot) HasDigestSize(size int) bool {
return root.DigestSize() == size
}

// validateBasic returns an error if the root (digest) length is not a power of two.
// validateBasic returns an error if the root digest size is not a power of two.
func (root MerkleSumRoot) validateBasic() error {
if !isPowerOfTwo(root.DigestSize()) {
return fmt.Errorf("MerkleSumRoot#validateBasic: invalid root length")
Expand Down

0 comments on commit e499540

Please sign in to comment.