Improve decisions debug output
parent
c02d2842b0
commit
d19b858e20
|
@ -197,15 +197,20 @@ class Decisions implements \Iterator, \Countable
|
|||
}
|
||||
}
|
||||
|
||||
public function __toString()
|
||||
public function toString(Pool $pool = null)
|
||||
{
|
||||
$decisionMap = $this->decisionMap;
|
||||
ksort($decisionMap);
|
||||
$str = '[';
|
||||
foreach ($decisionMap as $packageId => $level) {
|
||||
$str .= $packageId.':'.$level.',';
|
||||
$str .= (($pool) ? $pool->literalToPackage($packageId) : $packageId).':'.$level.',';
|
||||
}
|
||||
$str .= ']';
|
||||
return $str;
|
||||
}
|
||||
|
||||
public function __toString()
|
||||
{
|
||||
return $this->toString();
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue