From 017d3793e6fe8ae27fd47f4d5a3addcdbf17692f Mon Sep 17 00:00:00 2001 From: Tony Murray Date: Sun, 7 Jan 2018 10:25:12 -0600 Subject: [PATCH] Update validate --- LibreNMS/Validations/Php.php | 2 +- LibreNMS/Validations/Updates.php | 15 +++++++++++---- 2 files changed, 12 insertions(+), 5 deletions(-) diff --git a/LibreNMS/Validations/Php.php b/LibreNMS/Validations/Php.php index 0c296bd999..36d1e4c709 100644 --- a/LibreNMS/Validations/Php.php +++ b/LibreNMS/Validations/Php.php @@ -53,7 +53,7 @@ class Php implements ValidationGroup // if update is not set to false and version is min or newer if (Config::get('update') && version_compare(PHP_VERSION, $min_version, '<')) { - $validator->warn('PHP version 5.6.4 will be the minimum supported version on January 10, 2018. We recommend you update to PHP a supported version of PHP (7.1 suggested) to continue to receive updates. If you do not update PHP, LibreNMS will continue to function but stop receiving bug fixes and updates.'); + $validator->warn('PHP version 5.6.4 is the minimum supported version as of January 10, 2018. We recommend you update to PHP a supported version of PHP (7.1 suggested) to continue to receive updates. If you do not update PHP, LibreNMS will continue to function but stop receiving bug fixes and updates.'); } } diff --git a/LibreNMS/Validations/Updates.php b/LibreNMS/Validations/Updates.php index fdd171b5a8..c6140f75c4 100644 --- a/LibreNMS/Validations/Updates.php +++ b/LibreNMS/Validations/Updates.php @@ -62,10 +62,17 @@ class Updates implements ValidationGroup } if ($versions['local_branch'] != 'master') { - $validator->warn( - "Your local git branch is not master, this will prevent automatic updates.", - "You can switch back to master with git checkout master" - ); + if ($versions['local_branch'] == 'php53') { + $validator->warn( + "You are on the PHP 5.3 support branch, this will prevent automatic updates.", + "Update to PHP 5.6.4 or newer (PHP 7.1 recommended) to continue to receive updates." + ); + } else { + $validator->warn( + "Your local git branch is not master, this will prevent automatic updates.", + "You can switch back to master with git checkout master" + ); + } } }