mirror of
https://github.com/meilisearch/MeiliSearch
synced 2025-07-04 04:17:10 +02:00
fix: Break the proper loop when bucket sorting
This commit is contained in:
parent
d36a8abbc2
commit
671bd3374f
1 changed files with 2 additions and 2 deletions
|
@ -112,11 +112,11 @@ where D: Deref<Target=DB>,
|
|||
let mut groups = vec![documents.as_mut_slice()];
|
||||
let view = &self.view;
|
||||
|
||||
'group: for criterion in &self.criteria {
|
||||
for criterion in &self.criteria {
|
||||
let tmp_groups = mem::replace(&mut groups, Vec::new());
|
||||
let mut computed = 0;
|
||||
|
||||
for group in tmp_groups {
|
||||
'group: for group in tmp_groups {
|
||||
group.sort_unstable_by(|a, b| criterion.evaluate(a, b, view));
|
||||
for group in GroupByMut::new(group, |a, b| criterion.eq(a, b, view)) {
|
||||
computed += group.len();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue