Conditions | 1 |
Paths | 1 |
Total Lines | 9 |
Code Lines | 6 |
Lines | 0 |
Ratio | 0 % |
Tests | 0 |
CRAP Score | 2 |
Changes | 0 |
1 | <?php |
||
52 | public function setLocale(string $locale) : void |
||
53 | { |
||
54 | putenv(sprintf('LANG=%s.UTF-8', $locale)); |
||
55 | setlocale(LC_MESSAGES, sprintf('%s.UTF-8', $locale)); |
||
56 | |||
57 | bindtextdomain(self::DOMAIN, self::LANG_DIR); |
||
58 | bind_textdomain_codeset(self::DOMAIN, 'UTF-8'); |
||
59 | textdomain(self::DOMAIN); |
||
60 | } |
||
61 | |||
72 |