1
0
Fork 0

Create lock if we only have platform dependencies

pull/3804/head
Jordi Boggiano 2015-02-27 12:20:42 +00:00
parent e5985a9b55
commit 4d665f59b0
1 changed files with 4 additions and 4 deletions

View File

@ -258,7 +258,10 @@ class Locker
$lock['packages-dev'] = $this->lockPackages($devPackages); $lock['packages-dev'] = $this->lockPackages($devPackages);
} }
if (empty($lock['packages']) && empty($lock['packages-dev'])) { $lock['platform'] = $platformReqs;
$lock['platform-dev'] = $platformDevReqs;
if (empty($lock['packages']) && empty($lock['packages-dev']) && empty($lock['platform']) && empty($lock['platform-dev'])) {
if ($this->lockFile->exists()) { if ($this->lockFile->exists()) {
unlink($this->lockFile->getPath()); unlink($this->lockFile->getPath());
} }
@ -266,9 +269,6 @@ class Locker
return false; return false;
} }
$lock['platform'] = $platformReqs;
$lock['platform-dev'] = $platformDevReqs;
if (!$this->isLocked() || $lock !== $this->getLockData()) { if (!$this->isLocked() || $lock !== $this->getLockData()) {
$this->lockFile->write($lock); $this->lockFile->write($lock);
$this->lockDataCache = null; $this->lockDataCache = null;