[mms] Fix handling image attachments when added via the HTML editor Image dialog.