From d505132b179cb637ccd4f66e756b3a5dfb5b63d2 Mon Sep 17 00:00:00 2001 From: Bob Mottram Date: Sun, 22 Nov 2020 18:28:27 +0000 Subject: [PATCH] Published date --- newswire.py | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/newswire.py b/newswire.py index 5ef11b0c..c79a47c8 100644 --- a/newswire.py +++ b/newswire.py @@ -313,10 +313,13 @@ def atomFeedToDict(baseDir: str, domain: str, xmlStr: str, publishedDate = parseFeedDate(pubDate) if publishedDate: + pubDateStr = str(publishedDate) + if not pubDateStr.endswith('+00:00'): + pubDateStr += '+00:00' postFilename = '' votesStatus = [] addNewswireDictEntry(baseDir, domain, - result, str(publishedDate), + result, pubDateStr, title, link, votesStatus, postFilename, description, moderated, mirrored) @@ -377,10 +380,13 @@ def atomFeedYTToDict(baseDir: str, domain: str, xmlStr: str, publishedDate = parseFeedDate(pubDate) if publishedDate: + pubDateStr = str(publishedDate) + if not pubDateStr.endswith('+00:00'): + pubDateStr += '+00:00' postFilename = '' votesStatus = [] addNewswireDictEntry(baseDir, domain, - result, str(publishedDate), + result, pubDateStr, title, link, votesStatus, postFilename, description, moderated, mirrored)