From d26624902d2e0e0c20da65525729971a61a3deaf Mon Sep 17 00:00:00 2001 From: Geo Date: Thu, 2 Jun 2022 22:56:51 +0100 Subject: [PATCH] fix: inclusion of null locs in sitemap.xml Impacted by Hugo changes Fix #2732 --- wowchemy/layouts/_default/sitemap.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wowchemy/layouts/_default/sitemap.xml b/wowchemy/layouts/_default/sitemap.xml index b5761c61..9f607424 100644 --- a/wowchemy/layouts/_default/sitemap.xml +++ b/wowchemy/layouts/_default/sitemap.xml @@ -2,7 +2,7 @@ {{/* Check that page is built (has a URL) and is not private. */}} - {{ range where (where .Data.Pages "Permalink" "!=" nil) "Params.private" "ne" true }} + {{ range where (where .Data.Pages "Permalink" "!=" "") "Params.private" "ne" true }} {{ .Permalink }} {{- if not .Lastmod.IsZero }}{{ safeHTML ( .Lastmod.Format "2006-01-02T15:04:05-07:00" ) }}{{ end }}