Fix check proxy address (#125)

pull/127/head
sunshineplan 2020-09-21 16:36:55 +08:00 committed by IceCodeNew
parent 3e49d5b2cb
commit 4163816e8b
1 changed files with 1 additions and 1 deletions

View File

@ -152,7 +152,7 @@ judgment_parameters() {
break break
;; ;;
'-p' | '--proxy') '-p' | '--proxy')
if echo "${2:?undefine var}" | grep -qEo '^(https?|socks4a?|socks5h?):\/\/'; then if ! echo "${2:?undefine var}" | grep -qEo '^(https?|socks4a?|socks5h?):\/\/'; then
echo 'error: Please specify the correct proxy server address.' echo 'error: Please specify the correct proxy server address.'
exit 1 exit 1
fi fi