af_redditimgur: relax poster image url condition for imgur a bit

This commit is contained in:
Andrew Dolgov 2016-08-02 07:56:25 +03:00
parent 43db5b99eb
commit 49048482d8
1 changed files with 2 additions and 2 deletions

View File

@ -172,7 +172,7 @@ class Af_RedditImgur extends Plugin {
$source_stream = str_replace(".gifv", ".mp4", $entry->getAttribute("href"));
if (strpos($source_stream, "i.imgur.com") !== FALSE)
if (strpos($source_stream, "imgur.com") !== FALSE)
$poster_url = str_replace(".mp4", "h.jpg", $source_stream);
$this->handle_as_video($doc, $entry, $source_stream, $poster_url, $debug);
@ -259,7 +259,7 @@ class Af_RedditImgur extends Plugin {
$entry->parentNode->insertBefore($br, $entry);
} else if ($aentry->tagName == "source") {
if (strpos($url, "i.imgur.com") !== FALSE)
if (strpos($url, "imgur.com") !== FALSE)
$poster_url = str_replace(".mp4", "h.jpg", $url);
else
$poster_url = "";