Rename method
parent
418e876e8a
commit
536563dc2a
|
@ -258,7 +258,7 @@ class Installer
|
|||
$pool->addRepository($lockedRepository, $aliases);
|
||||
}
|
||||
|
||||
if (!$installFromLock || $this->locker->isLegacyFormat($devMode)) {
|
||||
if (!$installFromLock || !$this->locker->isCompleteFormat($devMode)) {
|
||||
$repositories = $this->repositoryManager->getRepositories();
|
||||
foreach ($repositories as $repository) {
|
||||
$pool->addRepository($repository, $aliases);
|
||||
|
|
|
@ -88,21 +88,21 @@ class Locker
|
|||
}
|
||||
|
||||
/**
|
||||
* Checks whether the lock file is in the legacy format
|
||||
* Checks whether the lock file is in the new complete format or not
|
||||
*
|
||||
* @param bool $dev true to check in dev mode
|
||||
* @return bool
|
||||
*/
|
||||
public function isLegacyFormat($dev)
|
||||
public function isCompleteFormat($dev)
|
||||
{
|
||||
$lockData = $this->getLockData();
|
||||
$lockedPackages = $dev ? $lockData['packages-dev'] : $lockData['packages'];
|
||||
|
||||
if (empty($lockedPackages) || isset($lockedPackages[0]['name'])) {
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
return true;
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in New Issue