소스 검색

Fix regression when using -vvv

Jordi Boggiano 11 년 전
부모
커밋
9cbfe31983
2개의 변경된 파일5개의 추가작업 그리고 2개의 파일을 삭제
  1. 3 1
      src/Composer/Downloader/FileDownloader.php
  2. 2 1
      src/Composer/Downloader/VcsDownloader.php

+ 3 - 1
src/Composer/Downloader/FileDownloader.php

@@ -97,7 +97,9 @@ class FileDownloader implements DownloaderInterface
                 } elseif (count($urls)) {
                     $this->io->write('');
                     $this->io->write('    Failed, trying the next URL');
-                } else {
+                }
+
+                if (!count($urls)) {
                     throw $e;
                 }
             }

+ 2 - 1
src/Composer/Downloader/VcsDownloader.php

@@ -67,7 +67,8 @@ abstract class VcsDownloader implements DownloaderInterface, ChangeReportInterfa
                     $this->io->write('Failed: ['.get_class($e).'] '.$e->getMessage());
                 } elseif (count($urls)) {
                     $this->io->write('    Failed, trying the next URL');
-                } else {
+                }
+                if (!count($urls)) {
                     throw $e;
                 }
             }