mirror of
https://github.com/composer/composer
synced 2025-05-10 17:12:51 +00:00
Allow optimizing fetching of dev versions only if no other stability is needed
This commit is contained in:
parent
a133e694d0
commit
e2f1e8aed6
1 changed files with 4 additions and 0 deletions
|
@ -676,6 +676,10 @@ class ComposerRepository extends ArrayRepository implements ConfigurableReposito
|
|||
if ($acceptableStabilities === null || $stabilityFlags === null || StabilityFilter::isPackageAcceptable($acceptableStabilities, $stabilityFlags, array($name), 'dev')) {
|
||||
$packageNames[$name.'~dev'] = $constraint;
|
||||
}
|
||||
// if only dev stability is requested, we skip loading the non dev file
|
||||
if (isset($acceptableStabilities['dev']) && count($acceptableStabilities) === 1 && count($stabilityFlags) === 0) {
|
||||
unset($packageNames[$name]);
|
||||
}
|
||||
}
|
||||
|
||||
foreach ($packageNames as $name => $constraint) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue