Keep the words typed after an inserted photo

FixEmailService
Shipped
September 2, 2026 at 8:19 AM UTC
Author
Kamo
Commit
d0110fb

The same reported message had a sign-off underneath its photo. That did not arrive either — the reading pane showed an empty body above the attachment. There is one body slot per type here, and the reader filled it from the first text part it met and dropped every later one. That is the right rule for multipart/alternative, whose parts are the same message rendered twice over and where picking one is the entire point (RFC 2046 §5.1.4). It was being applied to multipart/mixed as well, whose parts §5.1.3 says are all part of the message and are meant to be shown in the order they appear. The distinction never mattered while mail had a single text part. It matters on a phone: iPhone Mail splits what the sender typed around each photo they insert, so the message arrives as text / photo / text and everything past the first photo was discarded. Put the photo in first and the surviving part is empty, which is why this message read as blank. Text parts of a sequential multipart are now appended. Alternative siblings still resolve to a single version, including an alternative nested inside a mixed — the ordinary shape of mail that has an attachment — and an unparseable Content-Type falls to sequential, since discarding content is the destructive way to be wrong about it. Parsed against the reported message taken off the live mailbox: the body now ends in the sender's "Truly," and their sign-off rather than in three blank lines.

All changes

Like what you see shipping?

Every one of these updates lands in your workspace automatically. Start free and watch it grow week after week.

Start Free ForeverView Pricing