mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
Fixed injector usage in i18nTextCollector
Using singleton, which causes master strings to be cached
between modules with merge=true. Regression from a3c406e4d2
.
This commit is contained in:
parent
a3c406e4d2
commit
857af16b5b
@ -155,7 +155,7 @@ class i18nTextCollector extends Object {
|
||||
// Currently not possible because adapter instances can't be fully reset through the Zend API,
|
||||
// meaning master strings accumulate across modules
|
||||
if($mergeWithExisting) {
|
||||
$adapter = Injector::inst()->get('i18nRailsYamlAdapter');
|
||||
$adapter = Injector::inst()->create('i18nRailsYamlAdapter');
|
||||
$masterFile = "{$this->basePath}/{$module}/lang/"
|
||||
. $adapter->getFilenameForLocale($this->defaultLocale);
|
||||
if(!file_exists($masterFile)) continue;
|
||||
|
Loading…
Reference in New Issue
Block a user