diff options
author | Andrey Andreev <narf@devilix.net> | 2016-12-14 17:14:35 +0100 |
---|---|---|
committer | Andrey Andreev <narf@devilix.net> | 2016-12-14 17:14:35 +0100 |
commit | dcd6f5153b7e7e6d798d5a77af65b7460f152e5c (patch) | |
tree | 3f52a8b24fe55aeaf29f6cdb6dfa5b6e9f2ac095 /system/core/Utf8.php | |
parent | 24c866628d0ce5463d7e8b4eba512fa9e7752dfd (diff) |
Isolate CI_Security instantiation from CI_Input; improve tests
Diffstat (limited to 'system/core/Utf8.php')
-rw-r--r-- | system/core/Utf8.php | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/system/core/Utf8.php b/system/core/Utf8.php index 93c611675..042ca4316 100644 --- a/system/core/Utf8.php +++ b/system/core/Utf8.php @@ -57,13 +57,13 @@ class CI_Utf8 { * * @return void */ - public function __construct() + public function __construct($charset) { if ( - defined('PREG_BAD_UTF8_ERROR') // PCRE must support UTF-8 - && (ICONV_ENABLED === TRUE OR MB_ENABLED === TRUE) // iconv or mbstring must be installed - && strtoupper(config_item('charset')) === 'UTF-8' // Application charset must be UTF-8 - ) + defined('PREG_BAD_UTF8_ERROR') // PCRE must support UTF-8 + && (ICONV_ENABLED === TRUE OR MB_ENABLED === TRUE) // iconv or mbstring must be installed + && $charset === 'UTF-8' // Application charset must be UTF-8 + ) { define('UTF8_ENABLED', TRUE); log_message('info', 'UTF-8 Support Enabled'); |