diff --git a/ts/util/downloadAttachment.ts b/ts/util/downloadAttachment.ts index 0be52b9480bd..7ab95e8c2f4a 100644 --- a/ts/util/downloadAttachment.ts +++ b/ts/util/downloadAttachment.ts @@ -28,8 +28,8 @@ export async function downloadAttachment( try { downloaded = await doDownloadAttachment(server, migratedAttachment); } catch (error) { - // Attachments on the server expire after 30 days, then start returning 404 - if (error && error.code === 404) { + // Attachments on the server expire after 30 days, then start returning 404 or 403 + if (error && (error.code === 404 || error.code === 403)) { return null; }