]> git.immae.eu Git - github/wallabag/wallabag.git/blobdiff - inc/poche/Tools.class.php
some urls weren't well parsed
[github/wallabag/wallabag.git] / inc / poche / Tools.class.php
index d0e431663dcf5f9dc07aa1e904edf78bfe789cb7..4a72bae3defb9b252da525ab675b6abdd8b0c282 100644 (file)
@@ -170,6 +170,7 @@ class Tools
                 preg_match('#charset="?(.*)"#si', $meta[0], $encoding);
                 # if charset is found set it otherwise, set it to utf-8
                 $html_charset = (!empty($encoding[1])) ? strtolower($encoding[1]) : 'utf-8';
+                if (empty($encoding[1])) $encoding[1] = 'utf-8';
             } else {
                 $html_charset = 'utf-8';
                 $encoding[1] = '';