From 84da4d0de76c20baffc185aa713cab3a94c85266 Mon Sep 17 00:00:00 2001 From: Daniel Lang Date: Tue, 3 Jan 2017 08:11:22 -0800 Subject: [PATCH] Update documentation and test for sitemap template --- content/templates/sitemap.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/content/templates/sitemap.md b/content/templates/sitemap.md index 10cfeefbe..1ecbfb3be 100644 --- a/content/templates/sitemap.md +++ b/content/templates/sitemap.md @@ -37,8 +37,8 @@ Protocol](http://www.sitemaps.org/protocol.html). {{ range .Data.Pages }} - {{ .Permalink }} - {{ safeHTML ( .Date.Format "2006-01-02T15:04:05-07:00" ) }}{{ with .Sitemap.ChangeFreq }} + {{ .Permalink }}{{ if not .Lastmod.IsZero }} + {{ safeHTML ( .Lastmod.Format "2006-01-02T15:04:05-07:00" ) }}{{ end }}{{ with .Sitemap.ChangeFreq }} {{ . }}{{ end }}{{ if ge .Sitemap.Priority 0.0 }} {{ .Sitemap.Priority }}{{ end }}