Skip to content

Commit

Permalink
fix: do not attempt to canonicalize signature path if it does not exist
Browse files Browse the repository at this point in the history
  • Loading branch information
evilsocket committed Nov 8, 2024
1 parent b2a93b5 commit 83961ea
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/cli/signing.rs
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,11 @@ fn get_paths_of_interest(

fn signature_path(file_path: &Path, signature_path: Option<PathBuf>) -> PathBuf {
if let Some(path) = signature_path {
path.canonicalize().unwrap()
if path.exists() {
path.canonicalize().unwrap()
} else {
path
}
} else if file_path.is_file() {
file_path
.with_extension("signature")
Expand Down

0 comments on commit 83961ea

Please sign in to comment.