1 | <?php |
||
17 | class ResponseCreationListener implements EventSubscriberInterface |
||
18 | { |
||
19 | /** |
||
20 | * @var TranslatorInterface |
||
21 | */ |
||
22 | private $translator; |
||
23 | |||
24 | /** |
||
25 | * @var ClassMetadata |
||
26 | */ |
||
27 | private $metadata; |
||
28 | |||
29 | /** |
||
30 | * @var string |
||
31 | */ |
||
32 | private $apiKeyValue; |
||
33 | |||
34 | /** |
||
35 | * @var string |
||
36 | */ |
||
37 | private $messageValue; |
||
38 | |||
39 | /** |
||
40 | * Constructor. |
||
41 | * |
||
42 | * @param TranslatorInterface $translator |
||
43 | * @param ClassMetadata $classMetadata |
||
44 | * @param array $resultConfig |
||
45 | */ |
||
46 | 14 | public function __construct(TranslatorInterface $translator, ClassMetadata $classMetadata, array $resultConfig) |
|
53 | |||
54 | /** |
||
55 | * {@inheritdoc} |
||
56 | */ |
||
57 | 16 | public static function getSubscribedEvents() |
|
63 | |||
64 | /** |
||
65 | * Assembles the response. |
||
66 | * |
||
67 | * @param OnAssembleResponseEvent $event |
||
68 | */ |
||
69 | 14 | public function onResponseCreation(OnAssembleResponseEvent $event) |
|
84 | } |
||
85 |
This check looks at variables that are passed out again to other methods.
If the outgoing method call has stricter type requirements than the method itself, an issue is raised.
An additional type check may prevent trouble.