diff --git a/src/Composer/Repository/ArrayRepository.php b/src/Composer/Repository/ArrayRepository.php index 4f6e2daa7..a5023c1fe 100644 --- a/src/Composer/Repository/ArrayRepository.php +++ b/src/Composer/Repository/ArrayRepository.php @@ -26,6 +26,7 @@ use Composer\Package\LinkConstraint\VersionConstraint; */ class ArrayRepository implements RepositoryInterface { + /** @var PackageInterface[] */ protected $packages; public function __construct(array $packages = array()) diff --git a/src/Composer/Repository/WritableArrayRepository.php b/src/Composer/Repository/WritableArrayRepository.php index 756f24137..041e40562 100644 --- a/src/Composer/Repository/WritableArrayRepository.php +++ b/src/Composer/Repository/WritableArrayRepository.php @@ -42,7 +42,7 @@ class WritableArrayRepository extends ArrayRepository implements WritableReposit { $packages = $this->getPackages(); - // get at most one package of each name, prefering non-aliased ones + // get at most one package of each name, preferring non-aliased ones $packagesByName = array(); foreach ($packages as $package) { if (!isset($packagesByName[$package->getName()]) || $packagesByName[$package->getName()] instanceof AliasPackage) { diff --git a/src/Composer/Repository/WritableRepositoryInterface.php b/src/Composer/Repository/WritableRepositoryInterface.php index c046c377c..4500005d9 100644 --- a/src/Composer/Repository/WritableRepositoryInterface.php +++ b/src/Composer/Repository/WritableRepositoryInterface.php @@ -41,14 +41,14 @@ interface WritableRepositoryInterface extends RepositoryInterface public function removePackage(PackageInterface $package); /** - * Get unique packages, with aliases resolved and removed + * Get unique packages (at most one package of each name), with aliases resolved and removed. * * @return PackageInterface[] */ public function getCanonicalPackages(); /** - * Forces a reload of all packages + * Forces a reload of all packages. */ public function reload(); }