From aad1fa5bbf061ff294c7ebf2a51224938b12b19a Mon Sep 17 00:00:00 2001 From: fscarmen <62703343+fscarmen@users.noreply.github.com> Date: Sun, 27 Feb 2022 10:52:12 +0800 Subject: [PATCH] Update unlock.sh --- unlock.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/unlock.sh b/unlock.sh index 4a2940d..2660138 100644 --- a/unlock.sh +++ b/unlock.sh @@ -374,7 +374,8 @@ while getopts ":CcEeUu46SsM:m:A:a:N:n:T:t:" OPTNAME; do case "$OPTNAME" in 'C'|'c' ) L='C';; 'E'|'e' ) L='E';; - 'U'|'u' ) [ ! -e /etc/wireguard/warp_unlock.sh ] && red " ${T[${L}27]} " && exit 1 || uninstall;; + 'U'|'u' ) if [ ! -e /etc/wireguard/warp_unlock.sh ]; then red " ${T[${L}27]} " && exit 1 + else uninstall; exit 0; fi;; '4' ) TRACE4=$(curl -ks4m8 https://www.cloudflare.com/cdn-cgi/trace | grep warp | sed "s/warp=//g") [[ ! $TRACE4 =~ on|plus ]] && red " ${T[${L}24]} " && exit 1 || STATUS=(1 0 0);; '6' ) TRACE6=$(curl -ks6m8 https://www.cloudflare.com/cdn-cgi/trace | grep warp | sed "s/warp=//g")