]> git.immae.eu Git - github/wallabag/wallabag.git/blobdiff - src/Wallabag/CoreBundle/Helper/ContentProxy.php
Add tests for logic
[github/wallabag/wallabag.git] / src / Wallabag / CoreBundle / Helper / ContentProxy.php
index fab052685ccef748c6aba14591e05fc7866780cb..500901005c3df6b6906baa2d675aade2d0a5b119 100644 (file)
@@ -90,8 +90,8 @@ class ContentProxy
      * @return string (maybe contains invalid UTF-8 character)
      */
     private function convertPdfEncodingToUTF8($title) {
-        // first try UTF-16 (then UTF-8) because its easier to detect its present/absence
-        foreach (array('UTF-16BE', 'UTF-16LE', 'UTF-8', 'WINDOWS-1252') as $encoding) {
+        // first try UTF-8 because its easier to detect its present/absence
+        foreach (array('UTF-8', 'UTF-16BE', 'WINDOWS-1252') as $encoding) {
             if (mb_check_encoding($title, $encoding)) {
                 return mb_convert_encoding($title, 'UTF-8', $encoding);
             }