| 1 | <?php |
||
| 7 | final class ExtraLazyRpcClient implements RpcClientInterface |
||
| 8 | { |
||
| 9 | /** @var ExtraLazyResponseCollection */ |
||
| 10 | private $lazyCollection; |
||
| 11 | /** @var LazyRpcClient */ |
||
| 12 | private $client; |
||
| 13 | |||
| 14 | /** |
||
| 15 | * ExtraLazyRpcClient constructor. |
||
| 16 | * |
||
| 17 | * @param RpcClientInterface $client |
||
| 18 | */ |
||
| 19 | 4 | public function __construct(RpcClientInterface $client) |
|
| 23 | |||
| 24 | /** {@inheritdoc} */ |
||
| 25 | 4 | public function invoke($calls) |
|
| 35 | } |
||
| 36 |
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.