Skip to content
Snippets Groups Projects
Commit 0a02d484 authored by Christian Kuhn's avatar Christian Kuhn Committed by Wouter Wolters
Browse files

[BUGFIX] Flush l10n cache after translation update

The language module should flush l10n caches after translation
update, otherwise translation changes have no immediate effect.

Change-Id: Ibf412293139e6fc82da243ba22d7d13d187add5e
Resolves: #75778
Releases: master, 7.6
Reviewed-on: https://review.typo3.org/47780


Reviewed-by: default avatarGeorg Ringer <georg.ringer@gmail.com>
Tested-by: default avatarGeorg Ringer <georg.ringer@gmail.com>
Reviewed-by: default avatarWouter Wolters <typo3@wouterwolters.nl>
Tested-by: default avatarWouter Wolters <typo3@wouterwolters.nl>
parent cf446972
Branches
Tags
No related merge requests found
......@@ -14,6 +14,7 @@ namespace TYPO3\CMS\Lang\Command;
* The TYPO3 project - inspiring people to share!
*/
use TYPO3\CMS\Core\Cache\CacheManager;
use TYPO3\CMS\Core\Package\PackageInterface;
use TYPO3\CMS\Core\Package\PackageManager;
use TYPO3\CMS\Core\Utility\GeneralUtility;
......@@ -93,6 +94,8 @@ class LanguageCommandController extends CommandController
$this->output->progressAdvance();
}
}
// Flush language cache
GeneralUtility::makeInstance(CacheManager::class)->getCache('l10n')->flush();
$this->output->progressFinish();
}
......
......@@ -18,6 +18,7 @@ use TYPO3\CMS\Backend\Template\Components\ButtonBar;
use TYPO3\CMS\Backend\Template\Components\Menu\Menu;
use TYPO3\CMS\Backend\Template\Components\Menu\MenuItem;
use TYPO3\CMS\Backend\View\BackendTemplateView;
use TYPO3\CMS\Core\Cache\CacheManager;
use TYPO3\CMS\Core\Imaging\Icon;
use TYPO3\CMS\Core\Utility\GeneralUtility;
use TYPO3\CMS\Extbase\Mvc\Controller\ActionController;
......@@ -180,6 +181,8 @@ class LanguageController extends ActionController
$response['progress'] = $progress > 100 ? 100 : $progress;
}
$this->view->assign('response', $response);
// Flush language cache
GeneralUtility::makeInstance(CacheManager::class)->getCache('l10n')->flush();
}
/**
......@@ -201,6 +204,8 @@ class LanguageController extends ActionController
}
}
$this->view->assign('response', $response);
// Flush language cache
GeneralUtility::makeInstance(CacheManager::class)->getCache('l10n')->flush();
}
/**
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment