From eccea8a911b3e1714b3feea9596c1c958e6bf0c0 Mon Sep 17 00:00:00 2001 From: "Daniel (Fourdee)" Date: Sat, 21 Apr 2018 08:27:31 +0100 Subject: [PATCH] Minor + Fix indentation + Stick with case, add "On" to provide INFO print out, although its not technically required as INSTALL_WEB_SERVER=true is default value. --- automated install/basic-install.sh | 23 ++++++++++++++--------- 1 file changed, 14 insertions(+), 9 deletions(-) diff --git a/automated install/basic-install.sh b/automated install/basic-install.sh index d3330995..4cc106fe 100755 --- a/automated install/basic-install.sh +++ b/automated install/basic-install.sh @@ -974,15 +974,20 @@ setAdminFlag() { WebChooseOptions=("On (Recommended)" "" on Off "" off) WebChoices=$("${WebToggleCommand[@]}" "${WebChooseOptions[@]}" 2>&1 >/dev/tty) || (echo -e " ${COL_LIGHT_RED}Cancel was selected, exiting installer${COL_NC}" && exit 1) - # Depending on their choice - case ${WebChoices} in - Off) - echo -e " ${INFO} Web Server Off" - # or false - INSTALL_WEB_SERVER=false - ;; - esac - fi + # Depending on their choice + case ${WebChoices} in + "On (Recommended)") + echo -e " ${INFO} Web Server On" + # set it to true, as clearly seen below. + INSTALL_WEB_SERVER=true + ;; + Off) + echo -e " ${INFO} Web Server Off" + # or false + INSTALL_WEB_SERVER=false + ;; + esac + fi } # Check if /etc/dnsmasq.conf is from pi-hole. If so replace with an original and install new in .d directory