Browse Source

Attempt to address #103 using the hypothesis that css/js files may be modified (minified?) before being hashed in some situations

fix-133-memory-crash
Dan Janosik 6 years ago
parent
commit
d3ef035d00
No known key found for this signature in database GPG Key ID: C6F8CE9FFDB2CED2
  1. 9
      app.js

9
app.js

@ -71,6 +71,15 @@ app.use(session({
resave: false, resave: false,
saveUninitialized: false saveUninitialized: false
})); }));
app.use(function(req, res, next) {
if (req.url.match(/^.*(css|js)$/)) {
res.setHeader("Cache-Control", "no-transform");
}
next();
});
app.use(express.static(path.join(__dirname, 'public'))); app.use(express.static(path.join(__dirname, 'public')));
process.on("unhandledRejection", (reason, p) => { process.on("unhandledRejection", (reason, p) => {

Loading…
Cancel
Save