Add no-store cache header for zip downloads

This commit is contained in:
Alan Grainger
2026-09-04 23:27:28 +12:00
parent ff45919107
commit 3701d4e92c
5 changed files with 20 additions and 3 deletions
+1
View File
@@ -136,6 +136,7 @@ function startZipResponse (res: Response, share: SharedLink, archive: Archiver)
res.setHeader('Content-Disposition', `attachment; filename*=UTF-8''${filename}`)
// Hint to intermediate proxies (Nginx, etc.) not to buffer this response.
res.setHeader('X-Accel-Buffering', 'no')
res.setHeader('Cache-Control', 'no-store')
archive.pipe(res)
}