function PluginInstaller::install
@inheritDoc
Overrides LibraryInstaller::install
File
-
vendor/
composer/ composer/ src/ Composer/ Installer/ PluginInstaller.php, line 80
Class
- PluginInstaller
- Installer for plugin packages
Namespace
Composer\InstallerCode
public function install(InstalledRepositoryInterface $repo, PackageInterface $package) {
$promise = parent::install($repo, $package);
if (!$promise instanceof PromiseInterface) {
$promise = \React\Promise\resolve(null);
}
return $promise->then(function () use ($package, $repo) : void {
try {
Platform::workaroundFilesystemIssues();
$this->getPluginManager()
->registerPackage($package, true);
} catch (\Exception $e) {
$this->rollbackInstall($e, $repo, $package);
}
});
}