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

Breadcrumb

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

function Installer::setUpdateAllowTransitiveDependencies

Should dependencies of packages marked for update be updated?

Depending on the chosen constant this will either only update the directly named packages, all transitive dependencies which are not root requirement or all transitive dependencies including root requirements

Parameters

int $updateAllowTransitiveDependencies One of the UPDATE_ constants on the Request class:

Return value

Installer

File

vendor/composer/composer/src/Composer/Installer.php, line 1441

Class

Installer
@author Jordi Boggiano <j.boggiano@seld.be> @author Beau Simensen <beau@dflydev.com> @author Konstantin Kudryashov <ever.zet@gmail.com> @author Nils Adermann <naderman@naderman.de>

Namespace

Composer

Code

public function setUpdateAllowTransitiveDependencies(int $updateAllowTransitiveDependencies) : self {
    if (!in_array($updateAllowTransitiveDependencies, [
        Request::UPDATE_ONLY_LISTED,
        Request::UPDATE_LISTED_WITH_TRANSITIVE_DEPS_NO_ROOT_REQUIRE,
        Request::UPDATE_LISTED_WITH_TRANSITIVE_DEPS,
    ], true)) {
        throw new \RuntimeException("Invalid value for updateAllowTransitiveDependencies supplied");
    }
    $this->updateAllowTransitiveDependencies = $updateAllowTransitiveDependencies;
    return $this;
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal