Skip to content

Commit

Permalink
Merge pull request #3415 from jverdeyen/fix-translation-loader
Browse files Browse the repository at this point in the history
[TranslatorBundle] Fixed MessageCatalogue strict type (string) parameters in Translator Loader
  • Loading branch information
acrobat committed Apr 28, 2024
2 parents 9c6560b + 84d7a58 commit e90e1f9
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/Kunstmaan/TranslatorBundle/Service/Translator/Loader.php
Expand Up @@ -24,7 +24,11 @@ public function load($resource, $locale, $domain = 'messages')
$catalogue = new MessageCatalogue($locale);
$translations = $this->translationRepository->findBy(['locale' => $locale]);
foreach ($translations as $translation) {
$catalogue->set($translation->getKeyword(), $translation->getText(), $translation->getDomain());
$catalogue->set(
(string) $translation->getKeyword(),
(string) $translation->getText(),
(string) $translation->getDomain()
);
}
$this->catalogues[$locale] = $catalogue;
} else {
Expand Down

0 comments on commit e90e1f9

Please sign in to comment.