From: Andrew Dolgov Date: Thu, 9 Jul 2015 09:13:44 +0000 (+0300) Subject: redditimgur: don't try to readability parse twitter X-Git-Tag: 16.3~238 X-Git-Url: https://git.wh0rd.org/?a=commitdiff_plain;h=12d880d77a166e87aebe49b17e0247c06cec6024;hp=47888b3d87bc2399cb9fc23c595630e7bba801df;p=tt-rss.git redditimgur: don't try to readability parse twitter --- diff --git a/plugins/af_redditimgur/init.php b/plugins/af_redditimgur/init.php index a9f7f176..820c45d6 100644 --- a/plugins/af_redditimgur/init.php +++ b/plugins/af_redditimgur/init.php @@ -247,7 +247,9 @@ class Af_RedditImgur extends Plugin { $content_link = $xpath->query("(//a[contains(., '[link]')])")->item(0); - if ($content_link && strpos($content_link->getAttribute("href"), "reddit.com") === FALSE) { + if ($content_link && + strpos($content_link->getAttribute("href"), "twitter.com") === FALSE && + strpos($content_link->getAttribute("href"), "reddit.com") === FALSE) { /* link may lead to a huge video file or whatever, we need to check content type before trying to parse it which p much requires curl */