Use pool to match packages to avoid getting packages without ids, fixes #9094

main
Jordi Boggiano 4 years ago
parent 826db3db5e
commit ff757e649c
No known key found for this signature in database
GPG Key ID: 7BBD42C429EC80BC

@ -578,8 +578,8 @@ EOT
$matchedPackage = null;
$versions = array();
$matches = $repositorySet->findPackages($name, $constraint);
$pool = $repositorySet->createPoolForPackage($name);
$matches = $pool->whatProvides($name, $constraint);
foreach ($matches as $index => $package) {
// select an exact match if it is in the installed repo and no specific version was required
if (null === $version && $installedRepo->hasPackage($package)) {

Loading…
Cancel
Save