1 | <?php |
||
13 | abstract class BaseCommand extends Command |
||
14 | { |
||
15 | |||
16 | /** @var Client|ClientInterface */ |
||
17 | protected $client; |
||
18 | |||
19 | /** |
||
20 | * GetClassifiersCommand constructor. |
||
21 | * |
||
22 | * @param null|string $name |
||
23 | * @param ClientInterface $client |
||
24 | */ |
||
25 | public function __construct($name = null, ClientInterface $client = null) |
||
31 | |||
32 | /** |
||
33 | * @return Client |
||
34 | */ |
||
35 | public function getDefaultClient() |
||
39 | |||
40 | /** |
||
41 | * @return Client|ClientInterface |
||
42 | */ |
||
43 | public function getClient() |
||
47 | } |
||
48 |
Our type inference engine has found a suspicous assignment of a value to a property. This check raises an issue when a value that can be of a given class or a super-class is assigned to a property that is type hinted more strictly.
Either this assignment is in error or an instanceof check should be added for that assignment.