Skip to content

Commit 22e7533

Browse files
committed
fixed lastmod dateformat
1 parent f62df36 commit 22e7533

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

app/site/models/Sitemap.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,8 @@ function ($el) {
5454
'rewrite' => $rewrite->id,
5555
'changefreq' => $el->change_freq,
5656
'priority' => $el->priority,
57-
'loc' => $rewrite->getUrl(),
58-
'lastmod' => $rewrite->getUpdatedAt(),
57+
'loc' => $this->getRouting()->getUrl('frontend.root').ltrim($rewrite->getUrl(), '/'),
58+
'lastmod' => (new DateTime($rewrite->getUpdatedAt()))->format('Y-m-d'),
5959
];
6060
},
6161
$this->sitemap_rewriteList()->fetchAll()

0 commit comments

Comments
 (0)