From 6ebec8a810ac12ec9dd9bc8ec068ff1799ea3517 Mon Sep 17 00:00:00 2001 From: Tony Murray Date: Tue, 9 Jan 2018 16:28:29 -0600 Subject: [PATCH] Set notification error for old PHP version. --- daily.sh | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/daily.sh b/daily.sh index 4b20c38f7c..d424fd8b0c 100755 --- a/daily.sh +++ b/daily.sh @@ -127,14 +127,16 @@ set_notifiable_result() { check_php_ver() { local branch=$(git rev-parse --abbrev-ref HEAD) local ver_res=$(php -r "echo (int)version_compare(PHP_VERSION, '5.6.4', '<');") - if [[ "$branch" == "php53" && "$ver_res" == "0" ]]; then + if [[ "$branch" == "php53" ]] && [[ "$ver_res" == "0" ]]; then status_run "Supported PHP version, switched back to master branch." 'git checkout master' branch="master" - elif [[ "$branch" != "php53" && "$ver_res" == "1" ]]; then + elif [[ "$branch" != "php53" ]] && [[ "$ver_res" == "1" ]]; then status_run "Unsupported PHP version, switched to php53 branch." 'git checkout php53' branch="php53" fi + set_notifiable_result phpver ${ver_res} + return ${ver_res}; }