mirror of
https://github.com/composer/composer
synced 2025-05-09 08:32:56 +00:00
Remove useless if
This commit is contained in:
parent
cdf3b4e012
commit
9ffe0d13f5
1 changed files with 8 additions and 7 deletions
|
@ -57,15 +57,16 @@ class RuleWatchGraph
|
|||
if (!$node->getRule()->isDisabled() && !call_user_func($skipCallback, $otherWatch)) {
|
||||
$ruleLiterals = $node->getRule()->getLiterals();
|
||||
|
||||
if (sizeof($ruleLiterals) > 2) {
|
||||
foreach ($ruleLiterals as $ruleLiteral) {
|
||||
if ($otherWatch !== $ruleLiteral->getId() &&
|
||||
!call_user_func($conflictCallback, $ruleLiteral->getId())) {
|
||||
foreach ($ruleLiterals as $ruleLiteral) {
|
||||
$ruleLiteralId = $ruleLiteral->getId();
|
||||
|
||||
$this->moveWatch($literalId, $ruleLiteral->getId(), $node);
|
||||
if ($literalId !== $ruleLiteralId &&
|
||||
$otherWatch !== $ruleLiteralId &&
|
||||
!call_user_func($conflictCallback, $ruleLiteralId)) {
|
||||
|
||||
continue 2;
|
||||
}
|
||||
$this->moveWatch($literalId, $ruleLiteralId, $node);
|
||||
|
||||
continue 2;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue