From b0d132ee2ed9aa87992f6e7cb0011fd2e10233ec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9gis=20Hanol?= Date: Mon, 25 Nov 2013 19:47:53 +0100 Subject: [PATCH] make sure image urls have a scheme before pulling them in --- app/jobs/regular/pull_hotlinked_images.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/app/jobs/regular/pull_hotlinked_images.rb b/app/jobs/regular/pull_hotlinked_images.rb index cf7ded7ced..3ff3060aca 100644 --- a/app/jobs/regular/pull_hotlinked_images.rb +++ b/app/jobs/regular/pull_hotlinked_images.rb @@ -24,6 +24,7 @@ module Jobs extract_images_from(post.cooked).each do |image| src = image['src'] + src = "http:" + src if src.start_with?("//") if is_valid_image_url(src) begin