Browse Source

Conflict handling: lastWeakWhy stores a rule, not a rule id

Nils Adermann 13 years ago
parent
commit
e4f40272a3
1 changed files with 3 additions and 3 deletions
  1. 3 3
      src/Composer/DependencyResolver/Solver.php

+ 3 - 3
src/Composer/DependencyResolver/Solver.php

@@ -1544,9 +1544,9 @@ class Solver
         }
 
         if ($conflictRule->isWeak()) {
-            /** TODO why > or < lastWeakProblem? */
-            if (!$lastWeakWhy || $why > $lastWeakWhy) {
-                $lastWeakProblem = $why;
+            /** TODO why > or < lastWeakWhy? */
+            if (!$lastWeakWhy || $why > $lastWeakWhy->getId()) {
+                $lastWeakWhy = $conflictRule;
             }
         }