Skip to content

Commit e9e767f

Browse files
committed
Make sure we use the real default for vendor dir
1 parent 0129f96 commit e9e767f

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/johnpbloch/Composer/WordPressCoreInstaller.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,9 +58,10 @@ public function getInstallPath( PackageInterface $package ) {
5858
if ( ! $installationDir ) {
5959
$installationDir = 'wordpress';
6060
}
61+
$vendorDir = $this->composer->getConfig()->get( 'vendor-dir', Config::RELATIVE_PATHS ) ?: 'vendor';
6162
if (
6263
in_array( $installationDir, $this->sensitiveDirectories ) ||
63-
$installationDir === $this->composer->getConfig()->get( 'vendor-dir', Config::RELATIVE_PATHS )
64+
( $installationDir === $vendorDir )
6465
) {
6566
throw new \InvalidArgumentException( $this->getSensitiveDirectoryMessage( $installationDir, $prettyName ) );
6667
}

0 commit comments

Comments
 (0)