From 095afc5ea6bd8748cf6af9b9ad450bf315622c2c Mon Sep 17 00:00:00 2001 From: Harlan Wilton Date: Sat, 11 Nov 2023 19:35:25 +1100 Subject: [PATCH] fix: writing to runtime config bug --- src/runtime/sitemap/builder/sitemap.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/runtime/sitemap/builder/sitemap.ts b/src/runtime/sitemap/builder/sitemap.ts index 9490fab5..0213156d 100644 --- a/src/runtime/sitemap/builder/sitemap.ts +++ b/src/runtime/sitemap/builder/sitemap.ts @@ -73,7 +73,7 @@ export async function buildSitemap(sitemap: SitemapDefinition, resolvers: NitroU // 1. normalise const normalisedUrls = normaliseSitemapUrls(resolvedSources.map(e => e.urls).flat(), resolvers) // 2. enhance - const defaults = sitemap.defaults + const defaults = { ...(sitemap.defaults || {}) } if (autoLastmod && defaults?.lastmod) defaults.lastmod = new Date()