Fix clippy warnings

This commit is contained in:
Roey Darwish Dror
2018-07-10 07:29:41 +03:00
parent 42fa378cf7
commit 84b8f3b236
4 changed files with 16 additions and 19 deletions

View File

@@ -64,16 +64,14 @@ It's dangerous to run yay since Python based AUR packages will be installed in t
}
Command::new(yay).spawn()?.wait()?.check()?;
} else if let Some(sudo) = &sudo {
Command::new(&sudo)
.args(&["/usr/bin/pacman", "-Syu"])
.spawn()?
.wait()?
.check()?;
} else {
if let Some(sudo) = &sudo {
Command::new(&sudo)
.args(&["/usr/bin/pacman", "-Syu"])
.spawn()?
.wait()?
.check()?;
} else {
terminal.print_warning("No sudo or yay detected. Skipping system upgrade");
}
terminal.print_warning("No sudo or yay detected. Skipping system upgrade");
}
Ok(())