diff --git a/newswire.py b/newswire.py index 50beca8b..4c86ac59 100644 --- a/newswire.py +++ b/newswire.py @@ -190,7 +190,8 @@ def parseFeedDate(pubDate: str) -> str: pubDateStr = None if publishedDate: - publishedDate = publishedDate - publishedDate.utcoffset() + offset = publishedDate.utcoffset() + publishedDate = publishedDate - offset # convert local date to UTC publishedDate = publishedDate.replace(tzinfo=timezone.utc) pubDateStr = str(publishedDate)