return fallback locales whenever possible
This commit is contained in:
parent
6e75cee83e
commit
3c21650d9e
|
@ -95,7 +95,7 @@ class DataCollectorTranslator implements TranslatorInterface, TranslatorBagInter
|
|||
*/
|
||||
public function getFallbackLocales()
|
||||
{
|
||||
if ($this->translator instanceof Translator) {
|
||||
if ($this->translator instanceof Translator || method_exists($this->translator, 'getFallbackLocales')) {
|
||||
return $this->translator->getFallbackLocales();
|
||||
}
|
||||
|
||||
|
|
|
@ -95,7 +95,7 @@ class LoggingTranslator implements TranslatorInterface, TranslatorBagInterface
|
|||
*/
|
||||
public function getFallbackLocales()
|
||||
{
|
||||
if ($this->translator instanceof Translator) {
|
||||
if ($this->translator instanceof Translator || method_exists($this->translator, 'getFallbackLocales')) {
|
||||
return $this->translator->getFallbackLocales();
|
||||
}
|
||||
|
||||
|
|
Reference in New Issue