| 1 | <?php |
||
| 18 | final class ContainerBasedContainerAccessor implements ContainerAccessor |
||
| 19 | { |
||
| 20 | /** |
||
| 21 | * @var Container |
||
| 22 | */ |
||
| 23 | private $container; |
||
| 24 | |||
| 25 | /** |
||
| 26 | * @param Container $container |
||
| 27 | */ |
||
| 28 | public function __construct(ContainerInterface $container) |
||
| 32 | |||
| 33 | /** |
||
| 34 | * {@inheritdoc} |
||
| 35 | */ |
||
| 36 | public function getService(string $id) |
||
| 40 | |||
| 41 | /** |
||
| 42 | * {@inheritdoc} |
||
| 43 | */ |
||
| 44 | public function getParameters(): array |
||
| 57 | } |
||
| 58 |
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.