Skip to content

Commit

Permalink
Tidy
Browse files Browse the repository at this point in the history
  • Loading branch information
Hoverbear committed Jan 8, 2025
1 parent 5f71d03 commit 5cf259c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions crates/criticalup-cli/src/commands/run.rs
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,8 @@ pub(crate) async fn run(
let Some(binary_name) = components.next() else {
// This should never happen, the user somehow passed an empty string which clap somehow did not detect.
panic!("Unexpected error: In strict mode an empty string was found as a binary name, this code should have never been reached. Please report this.");
}; // `Components` has no `len`
if components.next().is_none() {
};
if components.next().is_some() {
// In strict mode, the specified binary cannot be anything other than a single path component,
// since it must be present in one of the bin dirs of the installations.
return Err(Error::StrictModeDoesNotAcceptPaths);
Expand Down

0 comments on commit 5cf259c

Please sign in to comment.