From: Andrew Dolgov Date: Wed, 13 Nov 2013 16:36:15 +0000 (+0400) Subject: add workaround for languagedetect idiotic shit of some kind X-Git-Tag: 1.11~22 X-Git-Url: https://git.wh0rd.org/?a=commitdiff_plain;h=5a450b87609b6638e1dcb288d9e566f005735f56;p=tt-rss.git add workaround for languagedetect idiotic shit of some kind --- diff --git a/include/rssfuncs.php b/include/rssfuncs.php index 43c02c7f..43d931fc 100644 --- a/include/rssfuncs.php +++ b/include/rssfuncs.php @@ -599,7 +599,12 @@ if (count($entry_language) > 0) { $entry_language = array_keys($entry_language); - $entry_language = db_escape_string(substr($entry_language[0], 0, 2)); + + // the fuck? + if (is_array($entry_language)) + $entry_language = ""; + else + $entry_language = db_escape_string(substr($entry_language[0], 0, 2)); _debug("detected language: $entry_language", $debug_enabled); }