This commit is contained in:
Kovid Goyal 2017-04-09 19:44:12 +05:30
parent 5b6a318d8a
commit 3feca0981a
2 changed files with 2 additions and 2 deletions

View File

@ -177,7 +177,7 @@ class Economist(BasicNewsRecipe):
for a in section.findNextSiblings('a', href=True): for a in section.findNextSiblings('a', href=True):
spans = a.findAll('span') spans = a.findAll('span')
if len(spans) == 2: if len(spans) == 2:
title = '{}: {}'.format(*map(self.tag_to_string, spans)) title = u'{}: {}'.format(*map(self.tag_to_string, spans))
else: else:
title = self.tag_to_string(a) title = self.tag_to_string(a)
articles.append({'title': title, 'url': process_url(a['href'])}) articles.append({'title': title, 'url': process_url(a['href'])})

View File

@ -177,7 +177,7 @@ class Economist(BasicNewsRecipe):
for a in section.findNextSiblings('a', href=True): for a in section.findNextSiblings('a', href=True):
spans = a.findAll('span') spans = a.findAll('span')
if len(spans) == 2: if len(spans) == 2:
title = '{}: {}'.format(*map(self.tag_to_string, spans)) title = u'{}: {}'.format(*map(self.tag_to_string, spans))
else: else:
title = self.tag_to_string(a) title = self.tag_to_string(a)
articles.append({'title': title, 'url': process_url(a['href'])}) articles.append({'title': title, 'url': process_url(a['href'])})