protected function ExtraPackage::mergeAutoload in Zircon Profile 8
Same name and namespace in other branches
- 8.0 vendor/wikimedia/composer-merge-plugin/src/Merge/ExtraPackage.php \Wikimedia\Composer\Merge\ExtraPackage::mergeAutoload()
Merge autoload or autoload-dev into a RootPackageInterface
Parameters
string $type 'autoload' or 'devAutoload':
RootPackageInterface $root:
1 call to ExtraPackage::mergeAutoload()
- ExtraPackage::mergeInto in vendor/
wikimedia/ composer-merge-plugin/ src/ Merge/ ExtraPackage.php - Merge this package into a RootPackageInterface
File
- vendor/
wikimedia/ composer-merge-plugin/ src/ Merge/ ExtraPackage.php, line 279
Class
- ExtraPackage
- Processing for a composer.json file that will be merged into a RootPackageInterface
Namespace
Wikimedia\Composer\MergeCode
protected function mergeAutoload($type, RootPackageInterface $root) {
$getter = 'get' . ucfirst($type);
$setter = 'set' . ucfirst($type);
$autoload = $this->package
->{$getter}();
if (empty($autoload)) {
return;
}
$unwrapped = self::unwrapIfNeeded($root, $setter);
$unwrapped
->{$setter}(array_merge_recursive($root
->{$getter}(), $this
->fixRelativePaths($autoload)));
}