From 41c7432feffbfc3607a51fed6e4f29ae7224c639 Mon Sep 17 00:00:00 2001 From: Jordi Boggiano Date: Sat, 13 Oct 2012 17:18:47 +0200 Subject: [PATCH] Do not fetch from repo for packages that obviously can not be there --- src/Composer/Repository/ComposerRepository.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/Composer/Repository/ComposerRepository.php b/src/Composer/Repository/ComposerRepository.php index 6fe23e9ae..f6339e32e 100644 --- a/src/Composer/Repository/ComposerRepository.php +++ b/src/Composer/Repository/ComposerRepository.php @@ -196,6 +196,10 @@ class ComposerRepository extends ArrayRepository implements NotifiableRepository public function whatProvides($name) { + if ($name === 'php' || in_array(substr($name, 0, 4), array('ext-', 'lib-'), true) || $name === '__root__') { + return array(); + } + if (isset($this->providers[$name])) { return $this->providers[$name]; }