real fix for fmt,clippy
CI / check (push) Successful in 1m17s
CI / docker (push) Successful in 2m17s

This commit is contained in:
Connor Johnstone
2026-04-01 23:25:14 -04:00
parent 494c8ddecb
commit ada336d945
+3 -5
View File
@@ -85,18 +85,16 @@ pub fn score_tracks(
} }
// Prefix match: local title starts with a top track name, or vice versa // Prefix match: local title starts with a top track name, or vice versa
if let Some(local) = title_lower.as_ref() { if let Some(local) = title_lower.as_ref()
if let Some((_, &pc)) = playcount_by_name && let Some((_, &pc)) = playcount_by_name
.iter() .iter()
.filter(|(top_name, _)| { .filter(|(top_name, _)| {
local.starts_with(top_name.as_str()) local.starts_with(top_name.as_str()) || top_name.starts_with(local.as_str())
|| top_name.starts_with(local.as_str())
}) })
.max_by_key(|&(_, &pc)| pc) .max_by_key(|&(_, &pc)| pc)
{ {
consider(pc); consider(pc);
} }
}
let playcount = best_playcount; let playcount = best_playcount;