mirror of
https://github.com/TECHNOFAB11/pay-respects.git
synced 2025-12-12 06:20:09 +01:00
refactor: replace String with &str in function parameters (codeberg #9)
Reviewed-on: https://codeberg.org/iff/pay-respects/pulls/9 Co-authored-by: Integral <integral@member.fsf.org> Co-committed-by: Integral <integral@member.fsf.org>
This commit is contained in:
parent
9728ce48a6
commit
aae2ce09f0
3 changed files with 11 additions and 13 deletions
|
|
@ -101,7 +101,7 @@ pub fn suggest_typo(typos: &[String], candidates: &[String], executables: &[Stri
|
|||
unreachable!("suggest_typo: must have at least two candidates")
|
||||
}
|
||||
}
|
||||
} else if let Some(suggest) = find_similar(typo, &candidates, Some(2)) {
|
||||
} else if let Some(suggest) = find_similar(typo, candidates, Some(2)) {
|
||||
suggestions.push(suggest);
|
||||
} else {
|
||||
suggestions.push(typo.to_string());
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue