From db1fa60a43aa64ca1316a724635afaa7300cd8e1 Mon Sep 17 00:00:00 2001 From: evazion Date: Wed, 3 May 2017 00:09:51 -0500 Subject: [PATCH] Set pawoo sources to html page after upload. --- app/logical/downloads/file.rb | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/app/logical/downloads/file.rb b/app/logical/downloads/file.rb index c2d55f0c1..2d9d39c5c 100644 --- a/app/logical/downloads/file.rb +++ b/app/logical/downloads/file.rb @@ -130,13 +130,18 @@ module Downloads def fix_twitter_sources(src) if src =~ %r!^https?://pbs\.twimg\.com/! && original_source =~ %r!^https?://twitter\.com/! original_source + elsif src =~ %r!^https?://img\.pawoo\.net/! && original_source =~ %r!^https?://pawoo\.net/! + original_source else src end end def set_source_to_referer(src) - if Sources::Strategies::Nijie.url_match?(src) || Sources::Strategies::Twitter.url_match?(src) || Sources::Strategies::Tumblr.url_match?(src) + if Sources::Strategies::Nijie.url_match?(src) || + Sources::Strategies::Twitter.url_match?(src) || + Sources::Strategies::Tumblr.url_match?(src) || + Sources::Strategies::Pawoo.url_match?(src) strategy = Sources::Site.new(src, :referer_url => options[:referer_url]) strategy.referer_url else