Skip to content

Commit

Permalink
Address clippy lint.
Browse files Browse the repository at this point in the history
  • Loading branch information
azriel91 committed Nov 3, 2022
1 parent 0f2950c commit c97b438
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions item_specs/file_download/src/file_download_ensure_op_spec.rs
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ where
// Ensure all parent directories are created
tokio::fs::create_dir_all(dest_parent)
.await
.or_else(|error| {
.map_err(|error| {
#[cfg(feature = "error_reporting")]
let dest_display = format!("{}", dest_path.display());
#[cfg(feature = "error_reporting")]
Expand All @@ -90,15 +90,15 @@ where
SourceSpan::from((start, dest_display.len()))
};

Err(FileDownloadError::DestParentDirsCreate {
FileDownloadError::DestParentDirsCreate {
dest: dest_path.to_path_buf(),
dest_parent: dest_parent.to_path_buf(),
#[cfg(feature = "error_reporting")]
dest_display,
#[cfg(feature = "error_reporting")]
parent_dirs_span,
error,
})
}
})?;
}
let dest_file = File::create(dest_path).await.or_else(|error| {
Expand Down

0 comments on commit c97b438

Please sign in to comment.