Fix MAIN_MESSAGE_INSTALL_MODULES_DISABLED_CONTACT_US

This commit is contained in:
Laurent Destailleur 2023-03-15 14:44:32 +01:00
parent c0c057197a
commit 9cd9150529

View File

@ -1123,7 +1123,11 @@ if ($mode == 'deploy') {
} else {
if (getDolGlobalString('MAIN_MESSAGE_INSTALL_MODULES_DISABLED_CONTACT_US')) {
// Show clean message
$message = info_admin($langs->trans('InstallModuleFromWebHasBeenDisabledContactUs'));
if (!is_numeric('MAIN_MESSAGE_INSTALL_MODULES_DISABLED_CONTACT_US')) {
$message = info_admin($langs->trans(getDolGlobalString('MAIN_MESSAGE_INSTALL_MODULES_DISABLED_CONTACT_US')));
} else {
$message = info_admin($langs->trans('InstallModuleFromWebHasBeenDisabledContactUs'));
}
} else {
// Show technical message
$message = info_admin($langs->trans("InstallModuleFromWebHasBeenDisabledByFile", $dolibarrdataroot.'/installmodules.lock'));