Hi everyone,
I am not sure if this is a bug or if I used to not do it the cake way.
For example I have a plugin with a templates where I use
__d('plugin_name', 'Some text to be transalted')
In my plugin I do have a plugins/PluginName/resources/templates/locales/fr/plugin_name.po
file for my default french translations. If I need to override the Translation in my App I used to create a new .po file resources/locales/fr/plugin_name.po
Since cakephp version 4.5.0 the loading of .po files has changed. I was able to spot the place that has changed from 4.4 to 4.5. The method translationsFolders()
in class Cake\I18n\MessagesFileLoader
returns the folders to search for .po files the otherway around. Plugin locale pathes are now returned first and the App locale pathes are last. That way I am not able to overload plugin .po files in my App, since the first folder that contains a valid .po file is used.
Can anyone confirm this behavior change is right and I do need to override plugin template translations some other way?