If description doesn't exist, use title instead

This commit is contained in:
Patrick Creech 2024-07-15 18:15:37 -04:00
parent ca64df8b20
commit fe5216bb1f

View file

@ -63,8 +63,7 @@ for feed in map(feedparser.parse, FedMag):
if not article_desc.startswith('<p>'): if not article_desc.startswith('<p>'):
article_desc = '<p>%s</p>' % article_desc article_desc = '<p>%s</p>' % article_desc
except AttributeError: except AttributeError:
print ('AttributeError. Going to next item') article_desc = title
continue
# we got # we got
# Tue, 20 Oct 2015 03:28:42 +0000 # Tue, 20 Oct 2015 03:28:42 +0000
# But we expect # But we expect