From e9a311ac67e60055101aa979de3ed227565e15d3 Mon Sep 17 00:00:00 2001 From: mitsuha_s Date: Sun, 12 Jun 2022 20:48:05 +0000 Subject: [PATCH] add feed title to Feed class --- rss.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/rss.py b/rss.py index f2ca995..1f6422b 100644 --- a/rss.py +++ b/rss.py @@ -12,7 +12,8 @@ class Feed: def __init__(self, url: str, feed: FeedParserDict) -> None: self.url = url self.items = [] - for item in feed: + self.title = feed.feed.get('title', '') + for item in feed.entries: self.items.append(FeedItem(item)) class RssReader: