fix missing translations

This commit is contained in:
Frédéric FRANCE 2025-02-06 13:31:18 +01:00
parent a9ef15ee55
commit ea2728afa0
No known key found for this signature in database
GPG Key ID: C06E4A9656127239

View File

@ -64,7 +64,7 @@ require_once DOL_DOCUMENT_ROOT.'/core/class/html.formmail.class.php';
*/
// Load translation files required by the page
$langs->loadLangs(array("admin", "other", "website", "errors"));
$langs->loadLangs(array("admin", "other", "website", "main", "errors"));
// Security check
if (!$user->hasRight('website', 'read')) {
@ -2078,12 +2078,10 @@ if ($action == 'updatemeta' && $usercanedit) {
$langs->load("errors");
if ($db->lasterrno == 'DB_ERROR_RECORD_ALREADY_EXISTS') {
$error++;
$langs->load("errors");
setEventMessages($langs->trans("ErrorAPageWithThisNameOrAliasAlreadyExists"), null, 'errors');
$action = 'editmeta';
} else {
$error++;
$langs->load("errors");
setEventMessages($objectpage->error, $objectpage->errors, 'errors');
$action = 'editmeta';
}