diff --git a/src/Composer/Repository/CompositeRepository.php b/src/Composer/Repository/CompositeRepository.php index e000d97e8..b01f2e7ca 100644 --- a/src/Composer/Repository/CompositeRepository.php +++ b/src/Composer/Repository/CompositeRepository.php @@ -91,6 +91,17 @@ class CompositeRepository implements RepositoryInterface return call_user_func_array('array_merge', $packages); } + /** + * {@inheritdoc} + */ + public function removePackage(PackageInterface $package) + { + foreach($this->repositories as $repository) { + /* @var $repository RepositoryInterface */ + $repository->removePackage($package); + } + } + /** * {@inheritdoc} */ diff --git a/src/Composer/Repository/RepositoryInterface.php b/src/Composer/Repository/RepositoryInterface.php index e4a79695d..de735c039 100644 --- a/src/Composer/Repository/RepositoryInterface.php +++ b/src/Composer/Repository/RepositoryInterface.php @@ -57,4 +57,11 @@ interface RepositoryInterface extends \Countable * @return array */ function getPackages(); + + /** + * @abstract + * @param \Composer\Package\PackageInterface $package + * @return void + */ + function removePackage(PackageInterface $package); }