Merge remote-tracking branch 'origin/support/2.7' into support/3.0

This commit is contained in:
Pierre Goiffon
2023-02-23 12:05:38 +01:00

View File

@@ -31,7 +31,7 @@ class MissingDependencyException extends CoreException
/** /**
* @return string HTML to print to the user the modules impacted * @return string HTML to print to the user the modules impacted
* @since 2.7.7 3.0.2 3.1.0 PR #280 * @since 2.7.7 3.0.2 3.1.0 N°5090 PR #280
*/ */
public function getHtmlDesc($sHighlightHtmlBegin = null, $sHighlightHtmlEnd = null) public function getHtmlDesc($sHighlightHtmlBegin = null, $sHighlightHtmlEnd = null)
{ {
@@ -261,10 +261,10 @@ class ModuleDiscovery
foreach($aDependencies as $sId => $aDeps) foreach($aDependencies as $sId => $aDeps)
{ {
$aModule = $aModules[$sId]; $aModule = $aModules[$sId];
$aModuleDeps[] = "{$aModule['label']} (id: $sId) depends on ".implode(' + ', $aDeps); $aModuleDeps[] = "{$aModule['label']} (id: $sId) depends on: ".implode(' + ', $aDeps);
$aModulesInfo[$sId] = array('module' => $aModule, 'dependencies' => $aDeps); $aModulesInfo[$sId] = array('module' => $aModule, 'dependencies' => $aDeps);
} }
$sMessage = "The following modules have unmet dependencies: ".implode(', ', $aModuleDeps); $sMessage = "The following modules have unmet dependencies:\n".implode(",\n", $aModuleDeps);
$oException = new MissingDependencyException($sMessage); $oException = new MissingDependencyException($sMessage);
$oException->aModulesInfo = $aModulesInfo; $oException->aModulesInfo = $aModulesInfo;
throw $oException; throw $oException;