original_string: protected function lookupInstalledPackage(Pool $pool, Link $link)
      {
          $packages = $pool->whatProvides($link->getTarget(), $link->getConstraint());
  
          return (!empty($packages)) ? $packages[0] : null;
      }
code: protected function lookupInstalledPackage(Pool $pool, Link $link)
      {
          $packages = $pool->whatProvides($link->getTarget(), $link->getConstraint());
  
          return (!empty($packages)) ? $packages[0] : null;
      }
code_tokens: protected function lookupInstalledPackage ( Pool $ pool , Link $ link ) { $ packages = $ pool -> whatProvides ( $ link -> getTarget ( ) , $ link -> getConstraint ( ) ) ; return ( ! empty ( $ packages ) ) ? $ packages [ 0 ] : null ; }
docstring: Resolves a package link to a package in the installed pool
  
  Since dependencies are already installed this should always find one.
  
  @param Pool $pool Pool of installed packages only
  @param Link $link Package link to look up
  
  @return PackageInterface|null The found package
docstring_tokens: Resolves a package link to a package in the installed pool