Conditions | 4 |
Paths | 4 |
Total Lines | 13 |
Code Lines | 5 |
Lines | 0 |
Ratio | 0 % |
Tests | 6 |
CRAP Score | 4 |
Changes | 0 |
1 | <?php declare(strict_types=1); |
||
60 | 32 | protected function outputValidValue(int $value): string |
|
61 | { |
||
62 | 32 | if ($value < 32) |
|
63 | { |
||
64 | 6 | return $this->escapeControlCode($value); |
|
65 | } |
||
66 | |||
67 | 26 | if ($value < 127) |
|
68 | { |
||
69 | 6 | return chr($value); |
|
70 | } |
||
71 | |||
72 | 20 | return ($value > 255) ? $this->escapeUnicode($value) : $this->escapeAscii($value); |
|
73 | } |
||
74 | } |