Ticket #3958: feedgenerator.diff

File feedgenerator.diff, 1.1 KB (added by Baptiste <baptiste.goupil@…>, 18 years ago)

the patch

  • utils/feedgenerator.py

     
    132132            handler.addQuickElement(u"category", cat)
    133133        if self.feed['feed_copyright'] is not None:
    134134            handler.addQuickElement(u"copyright", self.feed['feed_copyright'])
     135        handler.addQuickElement(u"lastBuildDate", rfc2822_date(self.latest_post_date()).decode('ascii'))
    135136        self.write_items(handler)
    136137        self.endChannelElement(handler)
    137138        handler.endElement(u"rss")
     
    199200        else:
    200201            handler.startElement(u"feed", {u"xmlns": self.ns})
    201202        handler.addQuickElement(u"title", self.feed['title'])
     203        if self.feed['description'] is not None:
     204            handler.addQuickElement(u"subtitle", self.feed['description'])
    202205        handler.addQuickElement(u"link", "", {u"rel": u"alternate", u"href": self.feed['link']})
    203206        if self.feed['feed_url'] is not None:
    204207            handler.addQuickElement(u"link", "", {u"rel": u"self", u"href": self.feed['feed_url']})
Back to Top