8000 [IdentityTranslator] fix compat with translation-contracts v2 · symfony/symfony@55559f4 · GitHub
[go: up one dir, main page]

Skip to content

Commit 55559f4

Browse files
[IdentityTranslator] fix compat with translation-contracts v2
1 parent a20e1ad commit 55559f4

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

src/Symfony/Component/Translation/IdentityTranslator.php

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,9 @@
2222
*/
2323
class IdentityTranslator implements LegacyTranslatorInterface, TranslatorInterface
2424
{
25-
use TranslatorTrait;
25+
use TranslatorTrait {
26+
trans as private doTrans;
27+
}
2628

2729
private $selector;
2830

@@ -35,6 +37,14 @@ public function __construct(MessageSelector $selector = null)
3537
}
3638
}
3739

40+
/**
41+
* {@inheritdoc}
42+
*/
43+
public function trans($id, array $parameters = [], $domain = null, $locale = null)
44+
{
45+
return $this->doTrans($id, $parameters, $domain, $locale);
46+
}
47+
3848
/**
3949
* {@inheritdoc}
4050
*

0 commit comments

Comments
 (0)
0