1
0
Fork 0

Using separate variable for URL parts

pull/1038/head
Christoph Hochstrasser 2012-08-29 15:12:08 +02:00
parent 841efc98a6
commit 560d6daccf
1 changed files with 3 additions and 1 deletions

View File

@ -191,7 +191,9 @@ class ComposerRepository extends ArrayRepository implements NotifiableRepository
}
try {
if ($parts = parse_url($this->url) and isset($parts['path']) and strpos($parts['path'], '/packages.json') !== false) {
$jsonUrlParts = parse_url($this->url);
if (isset($jsonUrlParts['path']) and strpos($jsonUrlParts['path'], '/packages.json') !== false) {
$jsonUrl = $this->url;
} else {
$jsonUrl = $this->url . '/packages.json';