1
0
Fork 0

Add output in why-not for when a package requires a platform package and it is not found, fixes #5259

pull/5267/head
Jordi Boggiano 2016-04-28 22:02:22 +01:00
parent 40df5dddee
commit 65a4719251
1 changed files with 6 additions and 2 deletions

View File

@ -121,7 +121,7 @@ abstract class BaseRepository implements RepositoryInterface
if (in_array($rootReq->getTarget(), $pkg->getNames()) && !$rootReq->getConstraint()->matches($link->getConstraint())) {
$results[] = array($package, $link, false);
$results[] = array($rootPackage, $rootReq, false);
break 2;
continue 3;
}
}
$results[] = array($package, $link, false);
@ -132,7 +132,11 @@ abstract class BaseRepository implements RepositoryInterface
}
}
break;
continue 2;
}
if (preg_match(PlatformRepository::PLATFORM_PACKAGE_REGEX, $link->getTarget())) {
$results[] = array($package, new Link($package->getName(), $link->getTarget(), null, 'requires', $link->getPrettyConstraint().' but it is missing'), false);
}
}
}