Fixed #23403 -- Fixed crash in contrib.sitemaps if lastmod returned a date rather than datetime.

Cool. I tested the new patch. It all works for me.