Update The New York Times Book Review

This commit is contained in:
Kovid Goyal 2016-03-20 17:55:48 +05:30
parent bb36ff93d7
commit 43f03aa6c2

View File

@ -12,8 +12,15 @@ class NewYorkTimesBookReview(BasicNewsRecipe):
encoding = 'utf-8'
keep_only_tags = [
dict(id=['story-heading', 'story-meta-footer']),
dict(id=['headline', 'story-meta-footer']),
dict(itemprop=['associatedMedia', 'articleBody', 'reviewBody']),
dict(attrs={'class':'story-body'}),
]
remove_tags = [
dict(id=['d-promo-realestate', 'books-update-email-promo']),
dict(attrs={'class':lambda x: x and 'skip-to-text-link' in x.split()}),
dict(attrs={'class':lambda x: x and 'story-meta-footer-sharetools' in x.split()}),
dict(attrs={'class':lambda x: x and 'story-footer-links' in x.split()}),
]
def parse_index(self):