From 6b2a2a52327907ae42827802ede2650329bd009c Mon Sep 17 00:00:00 2001 From: Lars Kiesow Date: Sat, 28 Sep 2013 01:19:04 +0200 Subject: [PATCH] Fixed attribute in Atom feed entries --- feedgen/entry.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/feedgen/entry.py b/feedgen/entry.py index 89f823c..68f7fa2 100644 --- a/feedgen/entry.py +++ b/feedgen/entry.py @@ -36,6 +36,7 @@ class FeedEntry(object): # optional self.__atom_category = None self.__atom_contributor = None + self.__atom_published = None self.__atom_source = None self.__atom_rights = None @@ -157,6 +158,10 @@ class FeedEntry(object): email = etree.SubElement(contrib, 'url') email.text = c.get('uri') + if self.__atom_published: + published = etree.SubElement(entry, 'published') + published.text = self.__atom_published.isoformat() + if self.__atom_rights: rights = etree.SubElement(feed, 'rights') rights.text = self.__atom_rights