We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 1ef309b commit 05ab615Copy full SHA for 05ab615
1 file changed
asap-planner-rs/src/query_log/frequency.rs
@@ -64,7 +64,7 @@ pub fn infer_queries(
64
65
for (_query_str, mut variants) in by_query {
66
// Sort descending by count so [0] is the most frequent variant.
67
- variants.sort_by(|a, b| b.1.len().cmp(&a.1.len()));
+ variants.sort_by_key(|b| std::cmp::Reverse(b.1.len()));
68
69
if variants.len() > 1 {
70
tracing::warn!(
0 commit comments