diff --git a/src/utils/mod.rs b/src/utils/mod.rs index a601287c7..42630bf5d 100644 --- a/src/utils/mod.rs +++ b/src/utils/mod.rs @@ -29,9 +29,6 @@ mod utf8 { /// Filter out list of paths that are not utf8 valid pub fn get_invalid_utf8_paths(paths: &[PathBuf]) -> Vec<&PathBuf> { - paths - .iter() - .filter_map(|path| is_invalid_utf8(path).then_some(path)) - .collect() + paths.iter().filter(|path| is_invalid_utf8(path)).collect() } }