Ticket #3958: feedgenerator.3.diff
File feedgenerator.3.diff, 1.7 KB (added by , 18 years ago) |
---|
-
utils/feedgenerator.py
132 132 handler.addQuickElement(u"category", cat) 133 133 if self.feed['feed_copyright'] is not None: 134 134 handler.addQuickElement(u"copyright", self.feed['feed_copyright']) 135 handler.addQuickElement(u"lastBuildDate", rfc2822_date(self.latest_post_date()).decode('ascii')) 135 136 self.write_items(handler) 136 137 self.endChannelElement(handler) 137 138 handler.endElement(u"rss") … … 199 200 else: 200 201 handler.startElement(u"feed", {u"xmlns": self.ns}) 201 202 handler.addQuickElement(u"title", self.feed['title']) 203 if self.feed['subtitle'] is not None or self.feed['description'] is not None: 204 handler.addQuickElement(u"subtitle", self.feed['subtitle'] or self.feed['description']) 202 205 handler.addQuickElement(u"link", "", {u"rel": u"alternate", u"href": self.feed['link']}) 203 206 if self.feed['feed_url'] is not None: 204 207 handler.addQuickElement(u"link", "", {u"rel": u"self", u"href": self.feed['feed_url']}) … … 212 215 if self.feed['author_link'] is not None: 213 216 handler.addQuickElement(u"uri", self.feed['author_link']) 214 217 handler.endElement(u"author") 215 if self.feed['subtitle'] is not None:216 handler.addQuickElement(u"subtitle", self.feed['subtitle'])217 218 for cat in self.feed['categories']: 218 219 handler.addQuickElement(u"category", "", {u"term": cat}) 219 220 if self.feed['feed_copyright'] is not None: