Fix bad logic

Before the formatting, the check was useless.
The fixes from the formatting/linting PR messed the logic.
This commit is contained in:
jo 2021-08-17 13:38:31 +02:00
parent 44477d0083
commit 60bd49fa62
1 changed files with 4 additions and 2 deletions

View File

@ -583,10 +583,12 @@ while :; do
shift
done
if [[ -z $web_root || ! -d $web_root ]]; then
echo "$web_root doesn't exist!"
# If web_root is given, check that it exists
if [[ -n $web_root && ! -d $web_root ]]; then
echo "$web_root directory not found!"
exit 1
fi
echo -e "\n.____ ._____. ___________.__ "
echo "| | |__\_ |_________ ___\__ ___/|__| _____ ____ "
echo "| | | || __ \_ __ \_/ __ \| | | |/ \_/ __ \ "