From 90d088edf769f08894089da0156d31f152ef84ee Mon Sep 17 00:00:00 2001 From: lowlighter <22963968+lowlighter@users.noreply.github.com> Date: Fri, 6 Nov 2020 20:04:06 +0100 Subject: [PATCH] Fix placeholder cache control --- src/app.mjs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/app.mjs b/src/app.mjs index 7977d939..3047f61f 100644 --- a/src/app.mjs +++ b/src/app.mjs @@ -35,7 +35,8 @@ } //Cache headers middleware middlewares.push((req, res, next) => { - res.header("Cache-Control", cached ? `public, max-age=${cached}` : "no-store, no-cache") + if (!["/placeholder"].includes(req.path)) + res.header("Cache-Control", cached ? `public, max-age=${cached}` : "no-store, no-cache") next() })