From af24f46803a0acb8ed74dd3b1ce9e41ca48e2d84 Mon Sep 17 00:00:00 2001 From: Eric Date: Thu, 7 Nov 2019 13:24:48 +0100 Subject: [PATCH] =?UTF-8?q?N=C2=B02249=20-=20Supportability=20-=20Updater?= =?UTF-8?q?=20module?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- setup/compiler.class.inc.php | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/setup/compiler.class.inc.php b/setup/compiler.class.inc.php index d7f9256c3..6fff623cc 100644 --- a/setup/compiler.class.inc.php +++ b/setup/compiler.class.inc.php @@ -110,13 +110,23 @@ class MFCompiler { $sFinalTargetDir = $sTargetDir; $bIsAlreadyInMaintenanceMode = SetupUtils::IsInMaintenanceMode(); + $sConfigFilePath = utils::GetConfigFilePath($this->sEnvironment); + if (is_file($sConfigFilePath)) + { + $oConfig = new Config($sConfigFilePath); + } + else + { + $oConfig = null; + } if ($bUseSymbolicLinks || $bSkipTempDir) { // Skip the creation of a temporary dictionary, not compatible with symbolic links $sTempTargetDir = $sFinalTargetDir; if (($this->sEnvironment == 'production') && !$bIsAlreadyInMaintenanceMode) { - SetupUtils::EnterMaintenanceMode(new Config(utils::GetConfigFilePath($this->sEnvironment))); + + SetupUtils::EnterMaintenanceMode($oConfig); } } else @@ -147,7 +157,7 @@ class MFCompiler // Move the results to the target directory if (($this->sEnvironment == 'production') && !$bIsAlreadyInMaintenanceMode) { - SetupUtils::EnterMaintenanceMode(new Config(utils::GetConfigFilePath($this->sEnvironment))); + SetupUtils::EnterMaintenanceMode($oConfig); } SetupUtils::movedir($sTempTargetDir, $sFinalTargetDir); }