From 2d37e8546e70dcf8c498560e3bc4d94e49856491 Mon Sep 17 00:00:00 2001 From: Vamsi Krishna Date: Mon, 28 Jun 2021 22:05:49 +0530 Subject: [PATCH] Fix decoded ampersands --- wiki/app.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/wiki/app.js b/wiki/app.js index 44e8783..1aff898 100644 --- a/wiki/app.js +++ b/wiki/app.js @@ -86,6 +86,9 @@ fs.readdir(inputDirectory, (err, items) => { cleanData = cleanData.replace(/\[\[(.*)\]\]/g, (match, p1) => { return `[${p1}](${url(p1)})`; }); + + // Replace decoded & -> & + cleanData = cleanData.replace(/&/g, "&"); // Create the new markdown header for Hugo. const newFileContents = `+++\r\ntitle = "${title}"\r\ndate = "${modified.toISOString()}"\r\n+++\r\n\r\n${cleanData}\r\n`;