Ignore self references when anlaysing independent root requirements
When creating a transaction we try to identify all requirements that are not themselves required by any other package. If a package references itself this should not mark it as being required by another package.pull/4989/head
parent
7b404c4717
commit
4af74b54e0
|
@ -165,7 +165,9 @@ class Transaction
|
|||
$possibleRequires = $this->pool->whatProvides($link->getTarget(), $link->getConstraint());
|
||||
|
||||
foreach ($possibleRequires as $require) {
|
||||
unset($roots[$require->id]);
|
||||
if ($require !== $package) {
|
||||
unset($roots[$require->id]);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -23,10 +23,7 @@ Circular dependencies are possible between packages
|
|||
{
|
||||
"name": "regular/pkg",
|
||||
"version": "1.0.0",
|
||||
"source": { "reference": "some.branch", "type": "git", "url": "" },
|
||||
"__dummy__require": {
|
||||
"require/itself": "1.0.0"
|
||||
}
|
||||
"source": { "reference": "some.branch", "type": "git", "url": "" }
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue