From 2fcdccc5a8df11098939714c51c7eac47114fcc7 Mon Sep 17 00:00:00 2001 From: alifeee Date: Wed, 1 Jan 2025 15:23:03 +0100 Subject: [PATCH] fix dates (month was off-by-1) --- notes/_build/.eleventy.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/notes/_build/.eleventy.js b/notes/_build/.eleventy.js index d5ff5df..fb037d3 100644 --- a/notes/_build/.eleventy.js +++ b/notes/_build/.eleventy.js @@ -68,9 +68,9 @@ export default function (eleventyConfig) { eleventyConfig.addFilter("fmt_date", (dateObj) => { let date = new Date(dateObj); - return `${date.getUTCFullYear()}-${("0" + date.getUTCMonth()).slice(-2)}-${( - "0" + date.getUTCDate() - ).slice(-2)}`; + return `${date.getUTCFullYear()}-${("0" + (date.getUTCMonth() + 1)).slice( + -2 + )}-${("0" + date.getUTCDate()).slice(-2)}`; }); // current date for rss feed eleventyConfig.addFilter("getNowDate", () => {