clippy fixes

This commit is contained in:
Folkert 2022-08-17 14:27:54 +02:00
parent 0ba5b3cfc6
commit f3f6f58d09
No known key found for this signature in database
GPG key ID: 1F17F6FFD112B97C
5 changed files with 6 additions and 11 deletions

View file

@ -55,8 +55,7 @@ fn flatten_directories(files: std::vec::Vec<PathBuf>) -> std::vec::Vec<PathBuf>
}
fn is_roc_file(path: &Path) -> bool {
let ext = path.extension().and_then(OsStr::to_str);
return matches!(ext, Some("roc"));
matches!(path.extension().and_then(OsStr::to_str), Some("roc"))
}
pub fn format(files: std::vec::Vec<PathBuf>, mode: FormatMode) -> Result<(), String> {