| 1 | <?php |
||
| 26 | class EventListener |
||
| 27 | { |
||
| 28 | /** |
||
| 29 | * @param RegisterDriverMetadataEventArgs $eventArgs |
||
| 30 | */ |
||
| 31 | public function registerDriverMetadata(RegisterDriverMetadataEventArgs $eventArgs) |
||
| 35 | |||
| 36 | /** |
||
| 37 | * @param LoadClassMetadataEventArgs $eventArgs |
||
| 38 | */ |
||
| 39 | public function postLoadClassMetadata(LoadClassMetadataEventArgs $eventArgs) |
||
| 43 | |||
| 44 | /** |
||
| 45 | * @param ClassMetadata $classMetadata |
||
| 46 | */ |
||
| 47 | protected function checkCoordinateType(ClassMetadata $classMetadata) |
||
| 60 | } |
||
| 61 |
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.