From 4badb9034424951bcc5bae12ca2d28c0f8c59fd9 Mon Sep 17 00:00:00 2001 From: Pierre Goiffon Date: Fri, 11 Sep 2020 19:08:58 +0200 Subject: [PATCH] =?UTF-8?q?N=C2=B02214=20Cron=20:=20remove=20:void=20to=20?= =?UTF-8?q?keep=20compatibility=20with=20PHP=20<=207.1=20see=20https://www?= =?UTF-8?q?.php.net/manual/fr/migration71.new-features.php#migration71.new?= =?UTF-8?q?-features.void-functions?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- setup/setuputils.class.inc.php | 2 +- webservices/cron.php | 6 ++---- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/setup/setuputils.class.inc.php b/setup/setuputils.class.inc.php index db526f3fd..4a35ad577 100644 --- a/setup/setuputils.class.inc.php +++ b/setup/setuputils.class.inc.php @@ -436,7 +436,7 @@ class SetupUtils * * @since 2.8.0 N°2214 replace SetupLog::Log calls by CheckResult::TRACE */ - private static function CheckPhpVersion(array &$aResult): void { + private static function CheckPhpVersion(array &$aResult) { $aResult[] = new CheckResult(CheckResult::TRACE, 'Info - CheckPHPVersion'); $sPhpVersion = phpversion(); diff --git a/webservices/cron.php b/webservices/cron.php index a870b00b2..3f55414f4 100644 --- a/webservices/cron.php +++ b/webservices/cron.php @@ -343,11 +343,9 @@ function CronExec($oP, $bVerbose, $bDebug=false) /** * @param \WebPage $oP */ -function CheckMaintenanceMode(Page $oP): void -{ +function CheckMaintenanceMode(Page $oP) { // Verify files instead of reloading the full config each time - if (file_exists(MAINTENANCE_MODE_FILE) || file_exists(READONLY_MODE_FILE)) - { + if (file_exists(MAINTENANCE_MODE_FILE) || file_exists(READONLY_MODE_FILE)) { $oP->p("Maintenance detected, exiting"); exit(EXIT_CODE_ERROR); }