image caching optimized

This commit is contained in:
2026-06-12 15:06:55 -05:00
parent 84c24b2e92
commit 577b63b7e7
3 changed files with 8 additions and 3 deletions

View File

@@ -16,6 +16,11 @@ async function bootstrap() {
//app.use('/bizmatch/payment/webhook', bodyParser.raw({ type: 'application/json' }));
// Serve static files from pictures directory
app.use('/pictures', express.static(PICTURES_DIR));
// Prevent browsers from caching 404s on /pictures/*
app.use('/pictures', (_req, res) => {
res.set('Cache-Control', 'no-store');
res.status(404).end();
});
app.setGlobalPrefix('bizmatch');