Only clone if needed

main
Jordi Boggiano 9 years ago
parent 33c123e8c2
commit 1d08f83976

@ -90,7 +90,7 @@ class ComposerRepository extends ArrayRepository implements ConfigurableReposito
$this->io = $io;
$this->cache = new Cache($io, $config->get('cache-repo-dir').'/'.preg_replace('{[^a-z0-9.]}i', '-', $this->url), 'a-z0-9.$');
$this->loader = new ArrayLoader();
if ($rfs) {
if ($rfs && $this->options) {
$rfs = clone $rfs;
$rfs->setOptions($this->options);
}

Loading…
Cancel
Save