Déplace le nettoyage des langues

This commit is contained in:
Fred Tempez 2023-03-29 10:19:56 +02:00
parent 937c36ca6d
commit dbd9d2bf34
2 changed files with 12 additions and 14 deletions

View File

@ -55,7 +55,7 @@ class common
// Numéro de version et branche pour l'auto-update
const ZWII_VERSION = '12.4.00';
const ZWII_DATAVERSION = 12301;
const ZWII_DATAVERSION = 12400;
// URL autoupdate
const ZWII_UPDATE_URL = 'https://forge.chapril.org/ZwiiCMS-Team/update/raw/branch/master/';

View File

@ -943,6 +943,16 @@ if ($this->getData(['core', 'dataVersion']) < 12301) {
$this->setData(['config', 'smtp', 'from', 'no-reply@' . str_replace('www.', '', $_SERVER['HTTP_HOST'])]);
// Mise à jour
$this->setData(['core', 'dataVersion', 12301]);
}
// Version 12.4.00
if ($this->getData(['core', 'dataVersion']) < 12400) {
// Nettoyage du dossier de langue d'installation'
unlink('core/vendor/tinymce/langs/langs.zip');
if (file_exists('core/module/install/ressource/i18n/de.json'))
@ -953,16 +963,4 @@ if ($this->getData(['core', 'dataVersion']) < 12301) {
unlink('core/module/install/ressource/i18n/pt_PT.json');
if (file_exists('core/module/install/ressource/i18n/gr_GR.json'))
unlink('core/module/install/ressource/i18n/gr_GR.json');
// Mise à jour
$this->setData(['core', 'dataVersion', 12301]);
}
// Version 12.4.00
/*
if ($this->getData(['core', 'dataVersion']) < 12400) {
// Mise à jour
$this->setData(['core', 'dataVersion', 12400]);
} */
}