Conditions | 1 |
Paths | 1 |
Total Lines | 6 |
Code Lines | 3 |
Lines | 0 |
Ratio | 0 % |
Tests | 4 |
CRAP Score | 1 |
Changes | 0 |
1 | <?php |
||
37 | 10 | public function encodeHtmlEntities(string $string): string |
|
38 | { |
||
39 | 10 | $string = \htmlspecialchars($string, ENT_QUOTES | ENT_SUBSTITUTE, 'UTF-8'); |
|
40 | 10 | $string = \str_replace(\array_keys(self::$replacements), \array_values(self::$replacements), $string); |
|
41 | |||
42 | 10 | return $string; |
|
43 | } |
||
45 |