From 99bb8b3bbbca9cc7b3079c1ff0ebb9388ca62328 Mon Sep 17 00:00:00 2001 From: Andrew Dolgov Date: Mon, 6 Jul 2015 23:59:10 +0300 Subject: [PATCH] af_redditimgur: do not embed content of reddit links --- plugins/af_redditimgur/init.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/plugins/af_redditimgur/init.php b/plugins/af_redditimgur/init.php index fe6d3240..d42f4c60 100644 --- a/plugins/af_redditimgur/init.php +++ b/plugins/af_redditimgur/init.php @@ -259,7 +259,8 @@ class Af_RedditImgur extends Plugin { $content_link = $xpath->query("(//a[contains(., '[link]')])")->item(0); - if ($content_link) { + if ($content_link && strpos($content_link->getAttribute("href"), "reddit.com") === FALSE) { + $tmp = fetch_file_contents($content_link->getAttribute("href")); if ($tmp) { -- 2.39.5