Skip to content

Commit

Permalink
cargo clippy
Browse files Browse the repository at this point in the history
  • Loading branch information
EvysGarden committed Oct 17, 2023
1 parent b094096 commit fdde5bf
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions src/freedesktop.rs
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ impl TrashContext {

full_paths
.iter()
.map(|path| {
let topdir = get_topdir_for_path(&path, &mount_points);
.try_for_each(|path| {
let topdir = get_topdir_for_path(path, &mount_points);

if topdir == home_topdir {
if path.starts_with(home_trash.as_path()) {
Expand All @@ -54,8 +54,7 @@ impl TrashContext {
}

Ok(())
})
.collect::<Result<(), _>>()?;
})?;

for path in full_paths {
debug!("Deleting {:?}", path);
Expand Down

0 comments on commit fdde5bf

Please sign in to comment.