Skip to content

Commit

Permalink
Adds exit point for folder not found
Browse files Browse the repository at this point in the history
  • Loading branch information
auyer committed Dec 14, 2023
1 parent d7ad003 commit 8c2c605
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions protonup-rs/src/download.rs
Original file line number Diff line number Diff line change
Expand Up @@ -176,6 +176,12 @@ pub async fn download_to_selected_app(app: Option<apps::App>) {
let install_dir: String = match app {
// If the user selected an app (Steam/Lutris)...
Some(app) => match app.detect_installation_method() {
installed_apps if installed_apps.len() == 0 => {

Check warning on line 179 in protonup-rs/src/download.rs

View workflow job for this annotation

GitHub Actions / clippy_check

length comparison to zero
println!("Install location for selected app(s) not found. Exiting.");
std::process::exit(0);
}


// Figure out which versions of the App the user has (Native/Flatpak)
installed_apps if installed_apps.len() == 1 => {
println!(
Expand Down

0 comments on commit 8c2c605

Please sign in to comment.