1
0
Fork 0

Fix invalid interface usage

pull/9873/head
Jordi Boggiano 2021-05-04 16:43:24 +02:00
parent 37f4f531d0
commit b268e20d9f
No known key found for this signature in database
GPG Key ID: 7BBD42C429EC80BC
1 changed files with 4 additions and 1 deletions

View File

@ -17,6 +17,7 @@ use Composer\DependencyResolver\Request;
use Composer\Installer;
use Composer\IO\IOInterface;
use Composer\Package\Loader\RootPackageLoader;
use Composer\Package\RootPackage;
use Composer\Plugin\CommandEvent;
use Composer\Plugin\PluginEvents;
use Composer\Package\Version\VersionParser;
@ -154,7 +155,9 @@ EOT
}
$rootPackage->setRequires($rootRequires);
$rootPackage->setDevRequires($rootDevRequires);
$rootPackage->setReferences(RootPackageLoader::extractReferences($reqs, $rootPackage->getReferences()));
if ($rootPackage instanceof RootPackage) {
$rootPackage->setReferences(RootPackageLoader::extractReferences($reqs, $rootPackage->getReferences()));
}
$rootPackage->setStabilityFlags(RootPackageLoader::extractStabilityFlags($reqs, $rootPackage->getMinimumStability(), $rootPackage->getStabilityFlags()));
if ($input->getOption('interactive')) {