1
0
mirror of https://github.com/xuthus83/pigallery2.git synced 2024-11-03 21:04:03 +08:00

Disable zip compression for better performance

This commit is contained in:
mcdamo 2021-05-04 10:07:43 +10:00
parent 07847e06c5
commit 13a09f0695

View File

@ -19,7 +19,6 @@ import {SearchQueryDTO, SearchQueryTypes} from '../../common/entities/SearchQuer
import {LocationLookupException} from '../exceptions/LocationLookupException';
import {SupportedFormats} from '../../common/SupportedFormats';
export class GalleryMWs {
@ -76,7 +75,9 @@ export class GalleryMWs {
res.set('Content-Type', 'application/zip');
res.set('Content-Disposition', 'attachment; filename=Gallery.zip');
const archive = archiver('zip');
const archive = archiver('zip', {
store: true, // disable compression
});
res.on('close', function() {
console.log('zip ' + archive.pointer() + ' bytes');