X-Git-Url: http://git.heureux-cyclage.org/?a=blobdiff_plain;f=maintenance%2FcheckComposerLockUpToDate.php;h=3f0a83ddf29c73674d64a122af520db4e4c88eef;hb=4ea621e2365319bbb8d35329bbd56a81ebe7251c;hp=7a85d64ab09f3248f228b7c029472fc71048f633;hpb=6c67ccee245313a619061952e865445dda584c64;p=lhc%2Fweb%2Fwiklou.git diff --git a/maintenance/checkComposerLockUpToDate.php b/maintenance/checkComposerLockUpToDate.php index 7a85d64ab0..3f0a83ddf2 100644 --- a/maintenance/checkComposerLockUpToDate.php +++ b/maintenance/checkComposerLockUpToDate.php @@ -12,8 +12,8 @@ require_once __DIR__ . '/Maintenance.php'; class CheckComposerLockUpToDate extends Maintenance { public function __construct() { parent::__construct(); - $this->mDescription = - 'Checks whether your composer.lock file is up to date with the current composer.json'; + $this->addDescription( + 'Checks whether your composer.lock file is up to date with the current composer.json' ); } public function execute() { @@ -34,11 +34,7 @@ class CheckComposerLockUpToDate extends Maintenance { $lock = new ComposerLock( $lockLocation ); $json = new ComposerJson( $jsonLocation ); - if ( $lock->getHash() === $json->getHash() ) { - $this->output( "Your composer.lock file is up to date with current dependencies!\n" ); - return; - } - // Out of date, lets figure out which dependencies are old + // Check all the dependencies to see if any are old $found = false; $installed = $lock->getInstalledDependencies(); foreach ( $json->getRequiredDependencies() as $name => $version ) { @@ -61,8 +57,6 @@ class CheckComposerLockUpToDate extends Maintenance { 1 ); } else { - // The hash is the entire composer.json file, - // so it can be updated without any of the dependencies changing // We couldn't find any out-of-date dependencies, so assume everything is ok! $this->output( "Your composer.lock file is up to date with current dependencies!\n" ); }