| Conditions | 2 |
| Paths | 2 |
| Total Lines | 9 |
| Code Lines | 4 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 5 |
| CRAP Score | 2 |
| Changes | 0 | ||
| 1 | <?php declare(strict_types=1); |
||
| 9 | 15 | public function __construct(string $message, Pointer $pointer, ?int $level = null, ?\Throwable $previous = null) |
|
| 10 | { |
||
| 11 | 15 | $message = \sprintf("%s while evaluating pointer '%s'", $message, (string)$pointer); |
|
| 12 | |||
| 13 | 15 | if ($level !== null) { |
|
| 14 | 3 | $message .= \sprintf(" at component '%s' (path component index %d)", $pointer->getPath()[$level], $level); |
|
| 15 | } |
||
| 16 | |||
| 17 | 15 | parent::__construct($message, 0, $previous); |
|
| 18 | } |
||
| 20 |