mirror of
https://git.joinsharkey.org/Sharkey/Sharkey.git
synced 2024-11-27 11:23:08 +02:00
fix
This commit is contained in:
parent
91d2c954fc
commit
2fbd09a07e
1 changed files with 1 additions and 1 deletions
|
@ -172,7 +172,7 @@ export class FileServerService {
|
||||||
ctx.set('Content-Disposition', contentDisposition('inline', filename));
|
ctx.set('Content-Disposition', contentDisposition('inline', filename));
|
||||||
} else {
|
} else {
|
||||||
const readable = this.internalStorageService.read(file.accessKey!);
|
const readable = this.internalStorageService.read(file.accessKey!);
|
||||||
readable.on('error', commonReadableHandlerGenerator(ctx));
|
readable.on('error', this.commonReadableHandlerGenerator(ctx));
|
||||||
ctx.body = readable;
|
ctx.body = readable;
|
||||||
ctx.set('Content-Type', FILE_TYPE_BROWSERSAFE.includes(file.type) ? file.type : 'application/octet-stream');
|
ctx.set('Content-Type', FILE_TYPE_BROWSERSAFE.includes(file.type) ? file.type : 'application/octet-stream');
|
||||||
ctx.set('Cache-Control', 'max-age=31536000, immutable');
|
ctx.set('Cache-Control', 'max-age=31536000, immutable');
|
||||||
|
|
Loading…
Reference in a new issue