1 | <?php |
||
11 | class RulesAdminListController extends AdminListController |
||
12 | { |
||
13 | /** |
||
14 | * @var RulesAdminListConfigurator |
||
15 | */ |
||
16 | private $configurator; |
||
17 | |||
18 | /** |
||
19 | * @return AdminListConfiguratorInterface |
||
20 | */ |
||
21 | public function getAdminListConfigurator($id) |
||
29 | |||
30 | /** |
||
31 | * The detail action |
||
32 | * |
||
33 | * @Route("/{popup}/rules", requirements={"popup" = "\d+"}, name="kunstmaanleadgenerationbundle_admin_rule_abstractrule_detail") |
||
34 | */ |
||
35 | public function detailAction(Request $request, $popup) |
||
39 | |||
40 | /** |
||
41 | * The add action |
||
42 | * |
||
43 | * @Route("/{popup}/add", requirements={"popup" = "\d+"}, name="kunstmaanleadgenerationbundle_admin_rule_abstractrule_add", methods={"GET", "POST"}) |
||
44 | * |
||
45 | * @return array |
||
46 | */ |
||
47 | public function addAction(Request $request, $popup) |
||
53 | |||
54 | /** |
||
55 | * The edit action |
||
56 | * |
||
57 | * @param int $id |
||
58 | * |
||
59 | * @Route("/{popup}/rules/{id}/edit", requirements={"popup" = "\d+", "rule" = "\d+"}, name="kunstmaanleadgenerationbundle_admin_rule_abstractrule_edit", methods={"GET", "POST"}) |
||
60 | * |
||
61 | * @return array |
||
62 | */ |
||
63 | public function editAction(Request $request, $id, $popup) |
||
67 | |||
68 | /** |
||
69 | * The delete action |
||
70 | * |
||
71 | * @param int $id |
||
72 | * |
||
73 | * @Route("/{popup}/rules/{id}/delete", requirements={"popup" = "\d+"}, name="kunstmaanleadgenerationbundle_admin_rule_abstractrule_delete", methods={"GET", "POST"}) |
||
74 | * |
||
75 | * @return array |
||
76 | */ |
||
77 | public function deleteAction(Request $request, $id, $popup) |
||
81 | } |
||
82 |
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.