From 6dc4faf386c3064b83743290dbeaf888bdd7cc39 Mon Sep 17 00:00:00 2001 From: alstjr7375 Date: Fri, 9 Jul 2021 12:21:54 +0900 Subject: [PATCH] Fix: Installer - invalid option check --- install.sh | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/install.sh b/install.sh index 3614c89..4bdbe21 100755 --- a/install.sh +++ b/install.sh @@ -439,15 +439,17 @@ select_profile() { #== Install Types ============================================================== leptonBranch="master" select_distribution() { + local selectedDistribution="" select distribution in "Original(default)" "Photon-Style" "Proton Style"; do + selectedDistribution="${distribution}" case "${distribution}" in - "Original") leptonBranch="master" ;; - "Photon-Style") leptonBranch="photon-style" ;; - "Proton-Style") leptonBranch="proton-style" ;; + "Original") leptonBranch="master"; break;; + "Photon-Style") leptonBranch="photon-style"; break;; + "Proton-Style") leptonBranch="proton-style"; break;; + *) echo "Invalid option, reselect please.";; esac - lepton_ok_message "Selected ${distribution}" - break done + lepton_ok_message "Selected ${selectedDistribution}" } leptonInstallType="Network" # Other types: Local, Release @@ -710,6 +712,7 @@ update_profile() { local Ver=$(git --git-dir "${LEPTONINFOFILE}" describe --tags --abbrev=0) git --git-dir "${LEPTONGITPATH}" checkout "tags/${Ver}" fi + check_chrome_restore else lepton_error_message "Unable to find update type, ${Type}" fi