Apply suggestions from code review

pull/104/head
IceCodeNew 2020-09-19 17:09:31 +08:00 committed by GitHub
parent d52f371751
commit 2ce0418303
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 2 deletions

View File

@ -112,10 +112,13 @@ judgment_parameters() {
while [[ "$#" -gt '0' ]]; do while [[ "$#" -gt '0' ]]; do
case "$1" in case "$1" in
'--remove') '--remove')
if [[ "$#" -gt '1' ]]; then
echo 'error: Please enter the correct parameters.'
exit 1
fi
REMOVE='1' REMOVE='1'
break ## 跳出while
;; ;;
'--specific') '--version')
VERSION="${2:?error: Please specify the correct version.}" VERSION="${2:?error: Please specify the correct version.}"
break ##跳出while break ##跳出while
;; ;;