From 16f5b14a52141d382de810658f2f2ad62f4489fc Mon Sep 17 00:00:00 2001 From: Anton Shevchuk Date: Fri, 22 Sep 2017 12:33:01 +0300 Subject: [PATCH] Hotfix vendor path --- src/Installers/Plugin.php | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/Installers/Plugin.php b/src/Installers/Plugin.php index 9e353ef..5f78c8e 100644 --- a/src/Installers/Plugin.php +++ b/src/Installers/Plugin.php @@ -43,6 +43,11 @@ class Plugin implements PluginInterface, EventSubscriberInterface */ protected $installer; + /** + * @var string + */ + protected $vendorPath; + /** * @var string */ @@ -72,6 +77,7 @@ public function __construct() public function activate(Composer $composer, IOInterface $io) { $this->installer = new Installer($io, $composer); + $this->vendorPath = $composer->getConfig()->get('vendor-dir'); $composer->getInstallationManager()->addInstaller($this->installer); } @@ -205,7 +211,7 @@ protected function copyExtras($files) { foreach ($files as $source => $target) { $this->copy( - dirname($this->installer->getVendorPath(), 2) . DS . $source, + $this->vendorPath . DS . $source, PATH_ROOT . DS . $target ); }