| Conditions | 3 |
| Paths | 4 |
| Total Lines | 7 |
| Code Lines | 5 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 5 |
| CRAP Score | 3.0416 |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 10 | 1 | public function getDocumentWidthFromOS(): int |
|
| 11 | { |
||
| 12 | 1 | $os = (PHP_OS_FAMILY === 'Windows' ? 'Windows' : isset($_SERVER['TERM'])) ? 'Unix' : 'undefined'; |
|
| 13 | 1 | return match ($os) { |
|
| 14 | 'Windows' => $this->getDocumentWidthWindows(), |
||
| 15 | 1 | 'Unix' => $this->getDocumentWidthUnix(), |
|
| 16 | 1 | default => 80 |
|
| 17 | }; |
||
| 37 |