WIP: attempt to fix cache issues

This commit is contained in:
Yuri Tatishchev 2025-06-16 23:01:52 -07:00
parent 2b7c256f4a
commit c9be11d58a
Signed by: CaZzzer
SSH Key Fingerprint: SHA256:sqXB3fe0LMpfH+IeM/vlmxKdso52kssrIJBlwKXVe1U

View File

@ -92,6 +92,13 @@ app.use(session({
logged: false
}));
// disable cache globally because it may break things between server restarts,
// since the paths aren't unique
app.use(function (req, res, next) {
res.setHeader("Cache-Control", "no-cache, no-store, must-revalidate");
next();
});
// home page
app.get("/", function (req, res) {
@ -181,4 +188,4 @@ server.listen(settings.server_port, settings.server_ip,
function get_time() {
let d = new Date();
return d.getTime();
}
}