Don't cache summit data (to prevent stale photo list being shown)

master
Manuel Kasper 2022-10-31 14:46:26 +01:00
rodzic 8e5e69fcb2
commit d998de87c3
1 zmienionych plików z 4 dodań i 0 usunięć

Wyświetl plik

@ -138,6 +138,10 @@ app.get('/summits/recent_photos/:associations/:days', (req, res) => {
});
app.get('/summits/:association/:code', (req, res) => {
res.cacheControl = {
noCache: true
};
db.getDb().collection('summits').findOne({code: req.params.association + '/' + req.params.code}, {projection: {'_id': false}}, (err, summit) => {
if (err) {
console.error(err);