diff --git a/scripts/health-check.sh b/scripts/health-check.sh index 7106922..1aa655d 100755 --- a/scripts/health-check.sh +++ b/scripts/health-check.sh @@ -32,10 +32,12 @@ function version_minor() { function program_exists() { local prog="$1" - if [[ $(which "$prog" &> /dev/null) ]]; then - echo "0" - else + which "$prog" &> /dev/null + + if [[ $? == "0" ]]; then echo "1" + else + echo "0" fi }