Skip to content

Commit

Permalink
Fix incorrect path in error message. (#22060)
Browse files Browse the repository at this point in the history
Also make two essentially identical errors
have a consistent message phrasing.
  • Loading branch information
benjyw authored Mar 9, 2025
1 parent b2b15a4 commit 8a81c64
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions src/rust/engine/fs/store/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1308,9 +1308,8 @@ impl Store {
.await
.map_err(|e| {
format!(
"Failed to set permissions for {}: {}",
"Error setting permissions on {}: {e}",
destination.display(),
e
)
})?;
}
Expand Down Expand Up @@ -1366,9 +1365,14 @@ impl Store {
destination.display()
)
})?;
tokio::fs::set_permissions(destination, FSPermissions::from_mode(mode))
tokio::fs::set_permissions(&destination, FSPermissions::from_mode(mode))
.await
.map_err(|e| format!("Error setting permissions on {}: {e}", path.display()))?;
.map_err(|e| {
format!(
"Error setting permissions on {}: {e}",
destination.display()
)
})?;
Ok(())
}
None => {
Expand Down

0 comments on commit 8a81c64

Please sign in to comment.