Skip to content

Commit

Permalink
fix #1210 - lastmod not generated for pages in sitemap.xml
Browse files Browse the repository at this point in the history
  • Loading branch information
codecalm committed Oct 10, 2022
1 parent 2e4b9c7 commit 3f862a8
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/pages/sitemap.xml
Expand Up @@ -20,9 +20,7 @@ layout: none
{% for page in pages %}
<url>
<loc>{% if jekyll.environment == 'preview' %}{{ site.preview-url }}{% endif %}{{ page.url | replace: '/index.html', '/' | absolute_url | xml_escape }}</loc>
{% if page.last_modified_at %}
<lastmod>{{ page.last_modified_at | date_to_xmlschema }}</lastmod>
{% endif %}
<lastmod>{{ page.last_modified_at | default: site.time | date_to_xmlschema }}</lastmod>
</url>
{% endfor %}

Expand Down

0 comments on commit 3f862a8

Please sign in to comment.