mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
News download: Fix a regression in 0.9.23 that prevented oldest_article from working with some RSS feeds.
This commit is contained in:
parent
06844b8e1a
commit
f5849facca
@ -184,7 +184,12 @@ class Feed(object):
|
|||||||
id = 'internal id#%s'%self.id_counter
|
id = 'internal id#%s'%self.id_counter
|
||||||
if id in self.added_articles:
|
if id in self.added_articles:
|
||||||
return
|
return
|
||||||
published = item.get('date_parsed', time.gmtime())
|
published = None
|
||||||
|
for date_field in ('date_parsed', 'published_parsed',
|
||||||
|
'updated_parsed'):
|
||||||
|
published = item.get(date_field, None)
|
||||||
|
if published is not None:
|
||||||
|
break
|
||||||
if not published:
|
if not published:
|
||||||
published = time.gmtime()
|
published = time.gmtime()
|
||||||
self.added_articles.append(id)
|
self.added_articles.append(id)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user