Closed
Description
There is bug when indexBy is meta key id introduced in doctrine pull
doctrine/orm#639
originally from issue
doctrine/orm#3094
doctrine/orm#1784
Buggy line is
where $typeOfField = $subMetadata->getTypeOfField($indexProperty);
returns null
-> $collectionKeyType = $this->getPhpType($typeOfField);
returns null
-> return array(new Type(null)
throws throw new \InvalidArgumentException(sprintf('"" is not a valid PHP type.', $builtinType));
I discoverred this bug when I attached Api Platform ApiLoader
https://github.com/api-platform/core/blob/master/src/Bridge/Symfony/Routing/ApiLoader.php#L108