Total Complexity | 3 |
Total Lines | 23 |
Duplicated Lines | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
10 | class IndexPriceKlineResponse extends AbstractResponse implements IIndexPriceKlineResponseInterface |
||
11 | { |
||
12 | /** |
||
13 | * @var IndexPriceKlineResponseItem[] |
||
14 | */ |
||
15 | private EntityCollection $list; |
||
16 | |||
17 | public function __construct(array $data) |
||
18 | { |
||
19 | $list = new EntityCollection(); |
||
20 | |||
21 | if (!empty($data['list'])) { |
||
22 | array_map(function ($item) use ($list) { |
||
23 | $list->push(ResponseDtoBuilder::make(IndexPriceKlineResponseItem::class, $item)); |
||
24 | }, $data['list']); |
||
25 | } |
||
26 | |||
27 | $this->list = $list; |
||
|
|||
28 | } |
||
29 | |||
30 | public function getKlineList(): array |
||
33 | } |
||
34 | } |
||
35 |
Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.
Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..