These results are based on our legacy PHP analysis, consider migrating to our new PHP analysis engine instead. Learn more
1 | <?php |
||
2 | |||
3 | namespace Kunstmaan\TranslatorBundle\Toolbar; |
||
4 | |||
5 | use Symfony\Component\Translation\TranslatorInterface; |
||
6 | use Symfony\Component\Translation\DataCollectorTranslator as BaseDataCollectorTranslator; |
||
7 | |||
8 | /** |
||
9 | * Class DataCollectorTranslator |
||
10 | */ |
||
11 | class DataCollectorTranslator extends BaseDataCollectorTranslator |
||
12 | { |
||
13 | /** |
||
14 | * @param TranslatorInterface $translator The translator must implement TranslatorBagInterface |
||
15 | */ |
||
16 | 3 | public function __construct(TranslatorInterface $translator) |
|
17 | { |
||
18 | 3 | parent::__construct($translator); |
|
0 ignored issues
–
show
|
|||
19 | 3 | } |
|
20 | } |
||
21 |
It seems like the type of the argument is not accepted by the function/method which you are calling.
In some cases, in particular if PHP’s automatic type-juggling kicks in this might be fine. In other cases, however this might be a bug.
We suggest to add an explicit type cast like in the following example: