1 | <?php |
||
24 | class RedirectController |
||
25 | { |
||
26 | /** |
||
27 | * @var RedirectRouteManagerInterface |
||
28 | */ |
||
29 | private $redirectRouteManager; |
||
30 | |||
31 | /** |
||
32 | * @var RouterInterface |
||
33 | */ |
||
34 | private $router; |
||
35 | |||
36 | /** |
||
37 | * Constructor. |
||
38 | * |
||
39 | * @param RedirectRouteManagerInterface $redirectRouteManager |
||
40 | * @param RouterInterface $router |
||
41 | */ |
||
42 | public function __construct(RedirectRouteManagerInterface $redirectRouteManager, RouterInterface $router) |
||
47 | |||
48 | /** |
||
49 | * Action to redirect based on a RedirectRouteInterface route. |
||
50 | * |
||
51 | * @param string $redirectRouteName |
||
52 | * |
||
53 | * @return RedirectResponse |
||
54 | * |
||
55 | * @throws NotFoundHttpException |
||
56 | */ |
||
57 | public function redirectAction($redirectRouteName) |
||
79 | } |
||
80 |
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: