Fix regression with pixiv manga uploads

This commit is contained in:
Toks
2014-12-11 13:21:43 -05:00
parent 029202068d
commit 6d565d9f87

View File

@@ -211,7 +211,13 @@ module Sources
end
def get_image_url_from_page(page, is_manga)
elements = page.search("div.works_display div img.big")
if is_manga
elements = page.search("div.works_display a img").find_all do |node|
node["src"] !~ /source\.pixiv\.net/
end
else
elements = page.search("div.works_display div img.big")
end
if elements.any?
element = elements.first