It seems like $collections of type array<integer,object<han...b\CollectionInterface>> is incompatible with the declared type array<integer,object<han...d\yaysondb\Collection>> of property $collections.
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..
Loading history...
25
}
26
27
/**
28
* Get collection
29
*
30
* @throws Exception\LogicException If id is not defined
31
*/
32
public function collection(string $id): CollectionInterface
33
{
34
if (!isset($this->collections[$id])) {
35
throw new Exception\LogicException("Trying to access undefined collection $id");
36
}
37
38
return $this->collections[$id];
39
}
40
41
/**
42
* Magic method to allow collection access through property name
43
*/
44
public function __get(string $id): CollectionInterface
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..