Bläddra i källkod

Merge pull request #2414 from matthieuauger/fix/2359/config-option-overwrite-cli

If installer sets prefer to false, the manager should too. Fixes #2359
Jordi Boggiano 12 år sedan
förälder
incheckning
c5be60b5c8
1 ändrade filer med 2 tillägg och 6 borttagningar
  1. 2 6
      src/Composer/Installer.php

+ 2 - 6
src/Composer/Installer.php

@@ -171,12 +171,8 @@ class Installer
         unset($devRepo, $package);
         // end BC
 
-        if ($this->preferSource) {
-            $this->downloadManager->setPreferSource(true);
-        }
-        if ($this->preferDist) {
-            $this->downloadManager->setPreferDist(true);
-        }
+        $this->downloadManager->setPreferSource($this->preferSource);
+        $this->downloadManager->setPreferDist($this->preferDist);
 
         // clone root package to have one in the installed repo that does not require anything
         // we don't want it to be uninstallable, but its requirements should not conflict