function UnknownPathExcluder::logExcludedPaths

Logs the paths that will be excluded from stage operations.

File

core/modules/package_manager/src/PathExcluder/UnknownPathExcluder.php, line 170

Class

UnknownPathExcluder
Excludes unknown paths from stage operations.

Namespace

Drupal\package_manager\PathExcluder

Code

public function logExcludedPaths() : void {
    $excluded_paths = $this->getExcludedPaths();
    if ($excluded_paths) {
        sort($excluded_paths);
        $message = $this->t("The following paths in @project_root aren't recognized as part of your Drupal site, so to be safe, Package Manager is excluding them from all stage operations. If these files are not needed for Composer to work properly in your site, no action is needed. Otherwise, you can disable this behavior by setting the <code>package_manager.settings:include_unknown_files_in_project_root</code> config setting to <code>TRUE</code>.\n\n@list", [
            '@project_root' => $this->pathLocator
                ->getProjectRoot(),
            '@list' => implode("\n", $excluded_paths),
        ]);
        $this->logger?->info($message);
    }
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.