1 | <?php |
||
18 | final class TaxonController extends Controller |
||
19 | { |
||
20 | /** |
||
21 | * @var TaxonRepositoryInterface |
||
22 | */ |
||
23 | private $taxonRepository; |
||
24 | |||
25 | /** |
||
26 | * @var ViewHandlerInterface |
||
27 | */ |
||
28 | private $viewHandler; |
||
29 | |||
30 | /** |
||
31 | * @var TaxonViewFactoryInterface |
||
32 | */ |
||
33 | private $taxonViewFactory; |
||
34 | |||
35 | /** |
||
36 | * @param TaxonRepositoryInterface $taxonRepository |
||
37 | * @param ViewHandlerInterface $viewHandler |
||
38 | * @param TaxonViewFactoryInterface $taxonViewFactory |
||
39 | */ |
||
40 | public function __construct( |
||
49 | |||
50 | /** |
||
51 | * @param Request $request |
||
52 | * |
||
53 | * @return Response |
||
54 | */ |
||
55 | public function showDetailsAction(Request $request) |
||
68 | /** |
||
69 | * @param Request $request |
||
70 | * |
||
71 | * @return Response |
||
72 | */ |
||
73 | public function showTreeAction(Request $request) |
||
87 | |||
88 | /** |
||
89 | * @param TaxonInterface $taxon |
||
90 | * @param string $locale |
||
91 | * |
||
92 | * @return TaxonView |
||
93 | */ |
||
94 | private function buildTaxonView(TaxonInterface $taxon, $locale) |
||
104 | } |
||
105 |
This check looks for parameters that are defined as one type in their type hint or doc comment but seem to be used as a narrower type, i.e an implementation of an interface or a subclass.
Consider changing the type of the parameter or doing an instanceof check before assuming your parameter is of the expected type.