Skip to content

Commit

Permalink
check version<0 in deleteVersion (#348)
Browse files Browse the repository at this point in the history
  • Loading branch information
erikgrinaker authored Dec 14, 2020
1 parent a07986e commit b3b6e2a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion mutable_tree.go
Original file line number Diff line number Diff line change
Expand Up @@ -516,7 +516,7 @@ func (tree *MutableTree) SaveVersion() ([]byte, int64, error) {
}

func (tree *MutableTree) deleteVersion(version int64) error {
if version == 0 {
if version <= 0 {
return errors.New("version must be greater than 0")
}
if version == tree.version {
Expand Down

0 comments on commit b3b6e2a

Please sign in to comment.