New attachment storage system

This commit is contained in:
Fedor Indutny 2024-07-11 12:44:09 -07:00 committed by GitHub
parent 273e1ccb15
commit 28664a606f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
161 changed files with 2418 additions and 1562 deletions

View file

@ -6,6 +6,7 @@ import { blobToArrayBuffer } from 'blob-util';
import * as log from '../logging/log';
import { scaleImageToLevel } from './scaleImageToLevel';
import { dropNull } from './dropNull';
import { getLocalAttachmentUrl } from './getLocalAttachmentUrl';
import type {
AttachmentType,
UploadedAttachmentType,
@ -36,7 +37,7 @@ export const downscaleOutgoingAttachment = async (
if (!path) {
return attachment;
}
scaleTarget = window.Signal.Migrations.getAbsoluteAttachmentPath(path);
scaleTarget = getLocalAttachmentUrl(attachment);
}
try {