]> git.wh0rd.org Git - tt-rss.git/commitdiff
update example reddit filter
authorAndrew Dolgov <fox@madoka.volgo-balt.ru>
Mon, 26 Nov 2012 10:38:33 +0000 (14:38 +0400)
committerAndrew Dolgov <fox@madoka.volgo-balt.ru>
Mon, 26 Nov 2012 10:38:33 +0000 (14:38 +0400)
classes/filter/redditimgur.php

index 6b41015e7b92b9933ef5c467da79772727b442d4..b9ed24353cb80b572807deee51cda63e4a4661e8 100644 (file)
@@ -15,7 +15,7 @@ class Filter_RedditImgur {
 
                                        foreach ($entries as $entry) {
                                                if ($entry->hasAttribute("href")) {
-                                                       if (preg_match("/i.imgur.com\/.*?.jpg/", $entry->getAttribute("href"))) {
+                                                       if (preg_match("/\.(jpg|jpeg|gif|png)$/i", $entry->getAttribute("href"))) {
 
                                                                $img = $doc->createElement('img');
                                                                $img->setAttribute("src", $entry->getAttribute("href"));