1
0
Fork 0

Fix loop and add missing options

pull/1205/head
Jordi Boggiano 2012-10-11 21:35:51 +02:00
parent 1d80720405
commit 116b822953
1 changed files with 3 additions and 1 deletions

View File

@ -279,7 +279,7 @@ class ComposerRepository extends ArrayRepository implements NotifiableRepository
$retries = 3; $retries = 3;
while ($retries--) { while ($retries--) {
try { try {
$json = new JsonFile($filename, new RemoteFilesystem($this->io)); $json = new JsonFile($filename, new RemoteFilesystem($this->io, $this->options));
$data = $json->read(); $data = $json->read();
$this->cache->write($cacheKey, json_encode($data)); $this->cache->write($cacheKey, json_encode($data));
@ -292,6 +292,8 @@ class ComposerRepository extends ArrayRepository implements NotifiableRepository
} }
$this->degradedMode = true; $this->degradedMode = true;
$data = json_decode($contents, true); $data = json_decode($contents, true);
break;
} elseif (!$retries) { } elseif (!$retries) {
throw $e; throw $e;
} }