This commit is contained in:
Kovid Goyal 2016-09-08 21:11:36 +05:30
parent 59e8070ef9
commit cc2757ebd8
2 changed files with 2 additions and 2 deletions

View File

@ -233,7 +233,7 @@ class WSJ(BasicNewsRecipe):
# return self.test_wsj_index() # return self.test_wsj_index()
root = self.index_to_soup(self.wsj_itp_page, as_tree=True) root = self.index_to_soup(self.wsj_itp_page, as_tree=True)
for span in CSSSelect('span.date-date')(root): for span in CSSSelect('span.date-date')(root):
if span.text: if span.text and span.text.strip():
self.timefmt = span.text self.timefmt = span.text
break break
for a in CSSSelect('div.itpSectionHeaderPdf a[href]')(root): for a in CSSSelect('div.itpSectionHeaderPdf a[href]')(root):

View File

@ -191,7 +191,7 @@ class WSJ(BasicNewsRecipe):
# return self.test_wsj_index() # return self.test_wsj_index()
root = self.index_to_soup(self.wsj_itp_page, as_tree=True) root = self.index_to_soup(self.wsj_itp_page, as_tree=True)
for span in CSSSelect('span.date-date')(root): for span in CSSSelect('span.date-date')(root):
if span.text: if span.text and span.text.strip():
self.timefmt = span.text self.timefmt = span.text
break break
for a in CSSSelect('div.itpSectionHeaderPdf a[href]')(root): for a in CSSSelect('div.itpSectionHeaderPdf a[href]')(root):