Description
Issue
When a package/module is created via ModuleBuilder, all instance application labels are incorrectly added in the package application language path.
This might provoque an inconsistency with other labels when the package is deployed.
Example:
This problem is even worse when working with multi-language instances.
Possible Fix
This bug was introduced with the Rector changes in this commit: b966550ea57bfc68926258d6e32d0e8a1416a798.
It is incorrectly adding all app_list_strings to the package application strings:
MBLanguage.php (lines 97-104).
It seems that the variable $app_list_strings
has always been empty, and the system was functioning just fine. However, this might have been an unnoticed bug until now.
Since we are unsure about the purpose of that condition, we have decided, for now, to simply remove line 86. This is effectively the same as removing the entire function, as it is currently doing nothing. Therefore, the loadAppListStrings
function should be properly analyzed to assess its necessity.
Steps to Reproduce the Issue
1.Create a new Package
2.Add a new basic module and save it
3.Check in custom/modulesbuilder/packages/.../application/language that the file has all application labels.
4. After deploy, in a multi-language environment, many core labels are overriden.
Context
We consider this as an critical issue.
Version
7.14.6
What browser are you currently using?
Chrome
Browser Version
No response
Environment Information
PHP 8.3 and 8.4
Operating System and Version
Ubuntu 23.10