function Installer::getInstallPath
Overrides LibraryInstaller::getInstallPath
File
-
vendor/
composer/ installers/ src/ Composer/ Installers/ Installer.php, line 139
Class
Namespace
Composer\InstallersCode
public function getInstallPath(PackageInterface $package) {
$type = $package->getType();
$frameworkType = $this->findFrameworkType($type);
if ($frameworkType === false) {
throw new \InvalidArgumentException('Sorry the package type of this package is not yet supported.');
}
$class = 'Composer\\Installers\\' . $this->supportedTypes[$frameworkType];
/**
* @var BaseInstaller
*/
$installer = new $class($package, $this->composer, $this->getIO());
$path = $installer->getInstallPath($package, $frameworkType);
if (!$this->filesystem
->isAbsolutePath($path)) {
$path = getcwd() . '/' . $path;
}
return $path;
}