#95212Form plugin translation doesn't work with YAML configuration (key : translationFiles)
Description
Hi,
following the official documentation ( [[https://docs.typo3.org/c/typo3/cms-form/master/en-us/I/Concepts/FormPlugin/Index.html#translation-of-form-plugin]] ) to translate the form plugin in backend, I set my YAML configuration like this :
TYPO3:
CMS:
Form:
prototypes:
standard:
formEngine:
translationFiles:
# custom translation file
20: 'EXT:my_site_package/Resources/Private/Language/Database.xlf'
But this file is never used.
I found in Form TranslationService (line 191 for version 10.4) that the translationFiles array is not replaced by a key-descending-sorted array (returned value from “sortArrayWithIntegerKeysDescending” method)
$this->sortArrayWithIntegerKeysDescending($translationFiles);
The translationFiles array remains the same, so the XLIFF file from the Form extension (at index 10) takes precedence over additional custom ones.
A fix could be :
$translationFiles = $this->sortArrayWithIntegerKeysDescending($translationFiles);
Note : version 11 is affected too.