| Conditions | 3 |
| Paths | 3 |
| Total Lines | 13 |
| Code Lines | 7 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 18 | public function __toString(): string |
||
| 19 | { |
||
| 20 | $messages = [sprintf("- %s\n", $this->getMessage())]; |
||
| 21 | $e = $this->getPrevious(); |
||
| 22 | if (! $e instanceof Exception) { |
||
|
|
|||
| 23 | return $this->getMainMessage($this); |
||
| 24 | } |
||
| 25 | |||
| 26 | if ($e instanceof self) { |
||
| 27 | return $this->buildMessage($e, $messages) . "\n" . $e->getTraceAsString(); |
||
| 28 | } |
||
| 29 | |||
| 30 | return parent::__toString(); |
||
| 31 | } |
||
| 63 |