Bladeren bron

Reverse new config-file changes

Zachary Flower 8 jaren geleden
bovenliggende
commit
8d6f8a6f42
2 gewijzigde bestanden met toevoegingen van 0 en 21 verwijderingen
  1. 0 11
      src/Composer/Config.php
  2. 0 10
      src/Composer/Factory.php

+ 0 - 11
src/Composer/Config.php

@@ -84,7 +84,6 @@ class Config
     private $configSource;
     /** @var ConfigSourceInterface */
     private $authConfigSource;
-    private $defaultsConfigSource;
     private $useEnvironment;
     private $warnedHosts = array();
 
@@ -121,16 +120,6 @@ class Config
         return $this->authConfigSource;
     }
 
-    public function setDefaultsConfigSource(ConfigSourceInterface $source)
-    {
-        $this->defaultsConfigSource = $source;
-    }
-
-    public function getDefaultsConfigSource()
-    {
-        return $this->defaultsConfigSource;
-    }
-
     /**
      * Merges new config values with the existing ones (overriding)
      *

+ 0 - 10
src/Composer/Factory.php

@@ -200,16 +200,6 @@ class Factory
         }
         $config->setAuthConfigSource(new JsonConfigSource($file, true));
 
-        // load global auth file
-        $file = new JsonFile($config->get('home').'/defaults.json');
-        if ($file->exists()) {
-            if ($io && $io->isDebug()) {
-                $io->writeError('Loading config file ' . $file->getPath());
-            }
-            $config->merge(array('config' => $file->read()));
-        }
-        $config->setDefaultsConfigSource(new JsonConfigSource($file, true));
-
         // load COMPOSER_AUTH environment variable if set
         if ($composerAuthEnv = getenv('COMPOSER_AUTH')) {
             $authData = json_decode($composerAuthEnv, true);