mirror of
https://github.com/Hopiu/wagtail.git
synced 2026-05-19 20:41:56 +00:00
Merge pull request #720 from kaedroho/use-lastest_revision_created_at-in-sitemap-generator
Use latest_revision_created_at in sitemap generator
This commit is contained in:
commit
b57fab3cca
1 changed files with 1 additions and 3 deletions
|
|
@ -818,12 +818,10 @@ class Page(six.with_metaclass(PageBase, MP_Node, ClusterableModel, index.Indexed
|
|||
return ['/']
|
||||
|
||||
def get_sitemap_urls(self):
|
||||
latest_revision = self.get_latest_revision()
|
||||
|
||||
return [
|
||||
{
|
||||
'location': self.full_url,
|
||||
'lastmod': latest_revision.created_at if latest_revision else None
|
||||
'lastmod': self.latest_revision_created_at
|
||||
}
|
||||
]
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue