Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. Package.php

function Package::getTargetDir

@inheritDoc

Overrides PackageInterface::getTargetDir

File

vendor/composer/composer/src/Composer/Package/Package.php, line 159

Class

Package
Core package definitions that are needed to resolve dependencies and install packages

Namespace

Composer\Package

Code

public function getTargetDir() : ?string {
    if (null === $this->targetDir) {
        return null;
    }
    return ltrim(Preg::replace('{ (?:^|[\\\\/]+) \\.\\.? (?:[\\\\/]+|$) (?:\\.\\.? (?:[\\\\/]+|$) )*}x', '/', $this->targetDir), '/');
}
RSS feed
Powered by Drupal