From 198a49454ee35446175e47d5b0c4669e87da53da Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Sun, 24 Apr 2016 20:39:00 +0530 Subject: [PATCH] Update TIME Magazine --- recipes/time_magazine.recipe | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/recipes/time_magazine.recipe b/recipes/time_magazine.recipe index 2e9b54068e..4e4353f1a5 100644 --- a/recipes/time_magazine.recipe +++ b/recipes/time_magazine.recipe @@ -96,6 +96,10 @@ class Time(JavascriptRecipe): ans['index'] = [('Articles', articles)] return ans + def preprocess_stage1(self, article, browser, url, recursion_level): + for img in browser.css_select('img[data-lazy-src]', all=True): + img.setAttribute('src', img.attribute('data-lazy-src')) + def load_complete(self, browser, url, rl): if self.time_initial_phase: browser.wait_for_element('footer.article-footer')