From c8ec64ec52f5d738994ce2863527fd4d10796c56 Mon Sep 17 00:00:00 2001 From: Storm Dragon Date: Thu, 26 Dec 2024 12:42:27 -0500 Subject: [PATCH] Fixed removal so it hopefully doesn't offer to remove ~/.local/games any more. --- linux-game-manager.sh | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/linux-game-manager.sh b/linux-game-manager.sh index 76a210b..94bf902 100755 --- a/linux-game-manager.sh +++ b/linux-game-manager.sh @@ -414,11 +414,13 @@ game_removal() { exit 0 fi # Create the menu of installed games - local selectedGame="$(dialog --backtitle "Linux Game Manager" \ + local selectedGame + selectedGame=$(dialog --backtitle "Linux Game Manager" \ --clear \ --no-tags \ - --menu "Please select a game to delete" 0 0 0 "${menuList[@]}" --stdout)" - [[ $? -ne 0 ]] && exit 0 + --menu "Please select a game to delete" 0 0 0 "${menuList[@]}" --stdout) + exitCode=$? + [[ $exitCode -ne 0 ]] && exit 0 # Get the actual game file paths local gameName="${selectedGame##*/}" gameName="${gameName%.sh}"