hnsw entry points - replace filter+next by find
@@ -98,9 +98,8 @@ impl EntryPoints {
{
self.entry_points
.iter()
- .filter(|entry| checker(entry.point_id))
+ .find(|entry| checker(entry.point_id))
.cloned()
- .next()
.or_else(|| {
// Searching for at least some entry point
self.extra_entry_points
