Fix attachment parsing and hasAttachment false positives

FixEmailService
ส่งแล้ว
25 เมษายน 2569 เวลา 00:09 UTC
ผู้เขียน
Kamo
ตั้งค่า
f1b46eb

Three fixes to EmailImapService: 1. toEnvelope: narrow multipart check to multipart/mixed only — plain HTML+text emails (multipart/alternative) no longer show a false positive paperclip icon in the message list 2. getMessage: reset hasAttachment after full parse so it accurately reflects whether real attachments were found, overriding the envelope heuristic 3. parseMultipart: use isMimeType("multipart/*") to detect nested multiparts instead of calling getContent() on every part (avoids pulling binary attachment content just for a type check, and prevents exceptions from binary parts from breaking the whole parse); also guard text/plain, text/html, and calendar parts against attachment-disposition so named .html/.txt/.ics files are treated as attachments rather than body content

เปลี่ยนแปลงทั้งหมด

เหมือนที่คุณเห็นการขนส่ง?

ทุก คน ที่ ได้ รับ การ ปรับ ปรุง เหล่า นี้ จะ ลง ไป ใน ที่ ทํา งาน ของ คุณ โดย อัตโนมัติ. เริ่มให้อิสระและดูมันเติบโตสัปดาห์แล้วสัปดาห์เล่า.

เริ่ม เป็น อิสระ ตลอด ไปแสดงพริ้นซ์