Fix undefined index error, fixes #2224
parent
72919e04b0
commit
80184b87d1
|
@ -275,7 +275,7 @@ EOT
|
||||||
}
|
}
|
||||||
|
|
||||||
// select highest version if we have many
|
// select highest version if we have many
|
||||||
$package = $candidates[0];
|
$package = reset($candidates);
|
||||||
foreach ($candidates as $candidate) {
|
foreach ($candidates as $candidate) {
|
||||||
if (version_compare($package->getVersion(), $candidate->getVersion(), '<')) {
|
if (version_compare($package->getVersion(), $candidate->getVersion(), '<')) {
|
||||||
$package = $candidate;
|
$package = $candidate;
|
||||||
|
|
Loading…
Reference in New Issue