mirror of
git://github.com/kovidgoyal/calibre.git
synced 2025-12-21 13:16:01 +01:00
Fix #5290 (Atlantic Feed Broken)
This commit is contained in:
parent
d0a546b3d6
commit
0dd72fe725
1 changed files with 7 additions and 6 deletions
|
|
@ -77,13 +77,14 @@ def parse_index(self):
|
|||
if poems:
|
||||
feeds.append(('Poems', poems))
|
||||
|
||||
self.log('Found section: Advice')
|
||||
div = soup.find(id='advice')
|
||||
title = self.tag_to_string(div.find('h4'))
|
||||
url = 'http://www.theatlantic.com'+div.find('a')['href']
|
||||
desc = self.tag_to_string(div.find('p'))
|
||||
self.log('\tFound article:', title, 'at', url)
|
||||
self.log('\t\t', desc)
|
||||
if div is not None:
|
||||
self.log('Found section: Advice')
|
||||
title = self.tag_to_string(div.find('h4'))
|
||||
url = 'http://www.theatlantic.com'+div.find('a')['href']
|
||||
desc = self.tag_to_string(div.find('p'))
|
||||
self.log('\tFound article:', title, 'at', url)
|
||||
self.log('\t\t', desc)
|
||||
|
||||
feeds.append(('Advice', [{'title':title, 'url':url, 'description':desc,
|
||||
'date':''}]))
|
||||
|
|
|
|||
Loading…
Reference in a new issue