Skip to content

Commit

Permalink
fix index Less panic
Browse files Browse the repository at this point in the history
  • Loading branch information
roseduan committed Mar 3, 2024
1 parent 0dbb007 commit a776163
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# Release 2.3.5(2024-03-03)
## 🐞 Bug Fixes
* Fix index Less function panic.

# Release 2.3.4(2024-01-07)

## 🎄 Enhancements
Expand Down
3 changes: 3 additions & 0 deletions index/btree.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,9 @@ func newBTree() *MemoryBTree {
}

func (it *item) Less(bi btree.Item) bool {
if bi == nil {
return false
}
return bytes.Compare(it.key, bi.(*item).key) < 0
}

Expand Down

0 comments on commit a776163

Please sign in to comment.