Skip to content

Commit

Permalink
fix warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
optozorax committed Aug 22, 2021
1 parent df7fb9e commit c0c8a2d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/lib.rs
Expand Up @@ -128,7 +128,7 @@ pub fn path(full: bool) -> String {
if full {
std::env::args().collect::<Vec<_>>().join(" ")
} else {
std::env::args().nth(0).unwrap()
std::env::args().next().unwrap()
}
}
}
Expand All @@ -141,7 +141,7 @@ pub fn path(full: bool) -> String {
pub fn easy_parse(param: &str) -> Option<(&str, Option<&str>)> {
let skip_len = if param.starts_with("--") {
"--".len()
} else if param.starts_with("-") {
} else if param.starts_with('-') {
"-".len()
} else {
return None;
Expand Down

0 comments on commit c0c8a2d

Please sign in to comment.