From d908827787c83aca69cf8257304cfd90f793aca2 Mon Sep 17 00:00:00 2001 From: Pierre Goiffon Date: Mon, 6 Mar 2023 11:24:46 +0100 Subject: [PATCH] =?UTF-8?q?N=C2=B06016=20Setup=20Wizard=20:=20fix=20Missin?= =?UTF-8?q?gDependencyException=20message=20logged=20as=20html=20in=20setu?= =?UTF-8?q?p.log?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Was the case since e831d66b (commit for parent bug N°5090) Now we are getting the text version in the log (and still the html one on screen) The unattended install isn't concerned : it just prints back CheckResult returned by \SetupUtils::CheckSelectedModules, with the exception text message ($e->getMessage()) --- setup/setuppage.class.inc.php | 16 ++++++++-------- setup/wizardsteps.class.inc.php | 2 +- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/setup/setuppage.class.inc.php b/setup/setuppage.class.inc.php index a25ad3d23..549af6f9c 100644 --- a/setup/setuppage.class.inc.php +++ b/setup/setuppage.class.inc.php @@ -62,28 +62,28 @@ class SetupPage extends NiceWebPage return ''; } - public function info($sText) + public function info($sText, $sTextForLog = null) { $this->add("

$sText

\n"); - $this->log_info($sText); + self::log_info($sTextForLog ?? $sText); } - public function ok($sText) + public function ok($sText, $sTextForLog = null) { $this->add("
Success:$sText
"); - $this->log_ok($sText); + self::log_ok($sTextForLog ?? $sText); } - public function warning($sText) + public function warning($sText, $sTextForLog = null) { $this->add("
Warning:$sText
"); - $this->log_warning($sText); + self::log_warning($sTextForLog ?? $sText); } - public function error($sText) + public function error($sText, $sTextForLog = null) { $this->add("
$sText
"); - $this->log_error($sText); + self::log_error($sTextForLog ?? $sText); } public function form($aData) diff --git a/setup/wizardsteps.class.inc.php b/setup/wizardsteps.class.inc.php index 9adb5692c..097aa07cd 100644 --- a/setup/wizardsteps.class.inc.php +++ b/setup/wizardsteps.class.inc.php @@ -1386,7 +1386,7 @@ class WizStepModulesChoice extends WizardStep } catch(MissingDependencyException $e) { - $oPage->warning($e->getHtmlDesc()); + $oPage->warning($e->getHtmlDesc(), $e->getMessage()); } $this->bUpgrade = ($this->oWizard->GetParameter('install_mode') != 'install');