diff --git a/src/Composer/Repository/ComposerRepository.php b/src/Composer/Repository/ComposerRepository.php index 218e23992..d62deb7c1 100644 --- a/src/Composer/Repository/ComposerRepository.php +++ b/src/Composer/Repository/ComposerRepository.php @@ -497,7 +497,10 @@ class ComposerRepository extends ArrayRepository implements ConfigurableReposito $this->sourceMirrors['hg'][] = array('url' => $mirror['hg-url'], 'preferred' => !empty($mirror['preferred'])); } if (!empty($mirror['dist-url'])) { - $this->distMirrors[] = array('url' => $mirror['dist-url'], 'preferred' => !empty($mirror['preferred'])); + $this->distMirrors[] = array( + 'url' => $this->canonicalizeUrl($mirror['dist-url']), + 'preferred' => !empty($mirror['preferred']) + ); } } }