Retain key for downloaded attachments
This commit is contained in:
parent
6f4730b42c
commit
9ebdf6e399
1 changed files with 2 additions and 2 deletions
|
@ -2,7 +2,7 @@
|
||||||
// SPDX-License-Identifier: AGPL-3.0-only
|
// SPDX-License-Identifier: AGPL-3.0-only
|
||||||
|
|
||||||
import { createWriteStream } from 'fs';
|
import { createWriteStream } from 'fs';
|
||||||
import { isNumber, omit } from 'lodash';
|
import { isNumber } from 'lodash';
|
||||||
import type { Readable } from 'stream';
|
import type { Readable } from 'stream';
|
||||||
import { Transform } from 'stream';
|
import { Transform } from 'stream';
|
||||||
import { pipeline } from 'stream/promises';
|
import { pipeline } from 'stream/promises';
|
||||||
|
@ -116,7 +116,7 @@ export async function downloadAttachmentV2(
|
||||||
safeUnlinkSync(cipherTextAbsolutePath);
|
safeUnlinkSync(cipherTextAbsolutePath);
|
||||||
|
|
||||||
return {
|
return {
|
||||||
...omit(attachment, 'key'),
|
...attachment,
|
||||||
path,
|
path,
|
||||||
size,
|
size,
|
||||||
contentType: contentType
|
contentType: contentType
|
||||||
|
|
Loading…
Reference in a new issue