Explorar o código

Define property before use

Jordi Boggiano %!s(int64=12) %!d(string=hai) anos
pai
achega
e618648f62
Modificáronse 1 ficheiros con 2 adicións e 1 borrados
  1. 2 1
      src/Composer/Package/Loader/ValidatingArrayLoader.php

+ 2 - 1
src/Composer/Package/Loader/ValidatingArrayLoader.php

@@ -24,6 +24,7 @@ class ValidatingArrayLoader implements LoaderInterface
     private $versionParser;
     private $ignoreErrors;
     private $errors = array();
+    private $config;
 
     public function __construct(LoaderInterface $loader, $ignoreErrors = true, VersionParser $parser = null)
     {
@@ -169,7 +170,7 @@ class ValidatingArrayLoader implements LoaderInterface
 
         $package = $this->loader->load($this->config);
         $this->errors = array();
-        unset($this->config);
+        $this->config = null;
 
         return $package;
     }