Ver Fonte

Remove unused policy function findUpdatePackages

Nils Adermann há 5 anos atrás
pai
commit
4f44b7b221

+ 0 - 13
src/Composer/DependencyResolver/DefaultPolicy.php

@@ -44,19 +44,6 @@ class DefaultPolicy implements PolicyInterface
         return $constraint->matchSpecific($version, true);
     }
 
-    public function findUpdatePackages(Pool $pool, PackageInterface $package, $mustMatchName = false)
-    {
-        $packages = array();
-
-        foreach ($pool->whatProvides($package->getName(), null, $mustMatchName) as $candidate) {
-            if ($candidate !== $package) {
-                $packages[] = $candidate;
-            }
-        }
-
-        return $packages;
-    }
-
     public function selectPreferredPackages(Pool $pool, array $literals, $requiredPackage = null)
     {
         $packages = $this->groupLiteralsByName($pool, $literals);

+ 0 - 3
src/Composer/DependencyResolver/PolicyInterface.php

@@ -20,8 +20,5 @@ use Composer\Package\PackageInterface;
 interface PolicyInterface
 {
     public function versionCompare(PackageInterface $a, PackageInterface $b, $operator);
-
-    public function findUpdatePackages(Pool $pool, PackageInterface $package);
-
     public function selectPreferredPackages(Pool $pool, array $literals, $requiredPackage = null);
 }