Reorder ArchiveManager parameters to make the download manager optional

main
Nils Adermann 12 years ago
parent a2b404e421
commit ba51027680

@ -319,12 +319,12 @@ class Factory
}
/**
* @param Downloader\DownloadManager $dm Manager use to download sources
* @param Config $config The configuration
* @param Downloader\DownloadManager $dm Manager use to download sources
*
* @return Archiver\ArchiveManager
*/
public function createArchiveManager(DownloadManager $dm = null, Config $config)
public function createArchiveManager(Config $config, DownloadManager $dm = null)
{
if (null === $dm) {
$dm = $this->createDownloadManager(new IO\NullIO(), $config);

@ -32,7 +32,7 @@ class ArchiveManagerTest extends ArchiverTest
parent::setUp();
$factory = new Factory();
$this->manager = $factory->createArchiveManager(null, $factory->createConfig());
$this->manager = $factory->createArchiveManager($factory->createConfig());
$this->targetDir = $this->testDir.'/composer_archiver_tests';
}

Loading…
Cancel
Save