]> git.wh0rd.org Git - tt-rss.git/commitdiff
af_redditimgur: add workaround for imgur switching to protocol-less links for images
authorAndrew Dolgov <fox@madoka.volgo-balt.ru>
Fri, 11 Oct 2013 09:41:30 +0000 (13:41 +0400)
committerAndrew Dolgov <fox@madoka.volgo-balt.ru>
Fri, 11 Oct 2013 09:41:30 +0000 (13:41 +0400)
plugins/af_redditimgur/init.php

index 2e466f167f88a78f1d510dc2ef09f77d31fe215b..e81d908e2647114bd070793aee2f3c44e09448d3 100644 (file)
@@ -62,7 +62,7 @@ class Af_RedditImgur extends Plugin {
                                                                                $aentries = $axpath->query('(//img[@src])');
 
                                                                                foreach ($aentries as $aentry) {
-                                                                                       if (preg_match("/^http:\/\/i.imgur.com\/$token\./", $aentry->getAttribute("src"))) {
+                                                                                       if (preg_match("/\/\/i.imgur.com\/$token\./", $aentry->getAttribute("src"))) {
                                                                                                $img = $doc->createElement('img');
                                                                                                $img->setAttribute("src", $aentry->getAttribute("src"));