| Conditions | 2 |
| Paths | 2 |
| Total Lines | 7 |
| Code Lines | 5 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 6 |
| CRAP Score | 2 |
| Changes | 0 | ||
| 1 | <?php |
||
| 13 | 2 | public static function fromCharset(string $shortCode, string $charSet, ?Throwable $previous = null): self |
|
| 14 | { |
||
| 15 | 2 | $code = $previous !== null ? $previous->getCode() : -1; |
|
| 16 | 2 | return new static( |
|
| 17 | 2 | sprintf('Provided short code "%s" does not match the char set "%s"', $shortCode, $charSet), |
|
| 18 | 2 | $code, |
|
| 19 | 2 | $previous |
|
| 20 | ); |
||
| 28 |