Fix mobile view Bugs and add versions to static files for cache breaking
This commit is contained in:
+2
-1
@@ -20,11 +20,12 @@ function sendFileResource(res, file, contentType = null) {
|
||||
if (contentType) res.type(contentType);
|
||||
res.setHeader('Content-Disposition', `inline; filename*=UTF-8''${encodeURIComponent(file.filename)}`);
|
||||
res.setHeader('X-Content-Type-Options', 'nosniff');
|
||||
res.setHeader('Cache-Control', 'no-cache, max-age=0, must-revalidate');
|
||||
return res.sendFile(file.absolutePath, {
|
||||
acceptRanges: true,
|
||||
cacheControl: true,
|
||||
immutable: false,
|
||||
maxAge: '1h'
|
||||
maxAge: 0
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user