Fixed UTF-8 issue in text parser
authorMarcel Werk <burntime@woltlab.com>
Tue, 7 Jun 2016 15:51:51 +0000 (17:51 +0200)
committerMarcel Werk <burntime@woltlab.com>
Tue, 7 Jun 2016 15:52:35 +0000 (17:52 +0200)
wcfsetup/install/files/lib/system/search/SearchResultTextParser.class.php

index 925499894c905cb602bcda641a4354ba56ef4364..106a43e3bc71184ecef2372fd9d6d483ad7706ee 100644 (file)
@@ -68,7 +68,7 @@ class SearchResultTextParser extends SingletonFactory {
         */
        protected function getMessageAbstract($text) {
                // replace newlines with spaces
-               $text = Regex::compile("\s+")->replace($text, ' ');
+               $text = Regex::compile("\s+", Regex::UTF_8)->replace($text, ' ');
                
                if (mb_strlen($text) > static::MAX_LENGTH) {
                        if ($this->searchQuery) {