diff --git a/apps/server/src/modules/files-storage/service/preview.service.spec.ts b/apps/server/src/modules/files-storage/service/preview.service.spec.ts index 61a886a353f..ed4592b97da 100644 --- a/apps/server/src/modules/files-storage/service/preview.service.spec.ts +++ b/apps/server/src/modules/files-storage/service/preview.service.spec.ts @@ -329,7 +329,7 @@ describe('PreviewService', () => { await previewService.getPreview(fileRecord, downloadParams, previewParams); - expect(resizeMock).toHaveBeenCalledWith(previewParams.width); + expect(resizeMock).toHaveBeenCalledWith(previewParams.width, undefined, '>'); expect(resizeMock).toHaveBeenCalledTimes(1); }); @@ -521,7 +521,7 @@ describe('PreviewService', () => { await previewService.getPreview(fileRecord, downloadParams, previewParams); - expect(resizeMock).toHaveBeenCalledWith(previewParams.width); + expect(resizeMock).toHaveBeenCalledWith(previewParams.width, undefined, '>'); expect(resizeMock).toHaveBeenCalledTimes(1); }); diff --git a/apps/server/src/modules/files-storage/service/preview.service.ts b/apps/server/src/modules/files-storage/service/preview.service.ts index 19e8ad39289..7cf33afe5fe 100644 --- a/apps/server/src/modules/files-storage/service/preview.service.ts +++ b/apps/server/src/modules/files-storage/service/preview.service.ts @@ -122,7 +122,7 @@ export class PreviewService { const { width } = previewParams; if (width) { - preview.resize(width); + preview.resize(width, undefined, '>'); } const result = preview.stream(format);