mirror of
https://github.com/schroinerxy/cloud-mail.git
synced 2026-06-21 19:35:50 +08:00
修复使用S3有时无法接收邮件
This commit is contained in:
@@ -14,7 +14,7 @@
|
||||
"wrangler": "^4.7.0"
|
||||
},
|
||||
"dependencies": {
|
||||
"@aws-sdk/client-s3": "^3.879.0",
|
||||
"@aws-sdk/client-s3": "^3.882.0",
|
||||
"@cloudflare/vite-plugin": "1.6.0",
|
||||
"dayjs": "^1.11.13",
|
||||
"drizzle-orm": "^0.42.0",
|
||||
|
||||
Generated
+439
-178
File diff suppressed because it is too large
Load Diff
@@ -147,7 +147,11 @@ export async function email(message, env, ctx) {
|
||||
});
|
||||
|
||||
if (attachments.length > 0 && await r2Service.hasOSS({env})) {
|
||||
await attService.addAtt({ env }, attachments);
|
||||
try {
|
||||
await attService.addAtt({ env }, attachments);
|
||||
} catch (e) {
|
||||
console.error(e)
|
||||
}
|
||||
}
|
||||
|
||||
emailRow = await emailService.completeReceive({ env }, account ? emailConst.status.RECEIVE : emailConst.status.NOONE, emailRow.emailId);
|
||||
|
||||
@@ -61,6 +61,7 @@ const s3Service = {
|
||||
accessKeyId: s3AccessKey,
|
||||
secretAccessKey: s3SecretKey,
|
||||
},
|
||||
forcePathStyle: true
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user