Bug 1997519 Comment 10 Edit History

Note: The actual edited comment in the bug view page will always show the original commenter’s name and original timestamp.

This issue is not limited to WebExtension APIs:

`composeWindow.SetComposeDetails({ body: "Something" })`

uses `editor.document.dDocumentElement.innerHtml =` [1] to update the
content of the editor. The `error` event hanlder used for handling
of blocked images is currently attached to `editor.document.body` [2].
After the editor content has been replaced as described, this event
listener no longer exists, and blocked images are therefore not handled
anymore.

[1]: https://searchfox.org/comm-central/rev/eb1b97b0f9c464d68d83064f4f68608369a37b75/mail/components/compose/content/MsgComposeCommands.js#6165
[2]: https://searchfox.org/comm-central/rev/eb1b97b0f9c464d68d83064f4f68608369a37b75/mail/components/compose/content/MsgComposeCommands.js#11222
The reported issue is not limited to WebExtension APIs:

`composeWindow.SetComposeDetails({ body: "Something" })`

uses `editor.document.documentElement.innerHtml =` [1] to update the
content of the editor. The `error` event hanlder used for handling
of blocked images is currently attached to `editor.document.body` [2].
After the editor content has been replaced as described, this event
listener no longer exists, and blocked images are therefore not handled
anymore.

[1]: https://searchfox.org/comm-central/rev/eb1b97b0f9c464d68d83064f4f68608369a37b75/mail/components/compose/content/MsgComposeCommands.js#6165
[2]: https://searchfox.org/comm-central/rev/eb1b97b0f9c464d68d83064f4f68608369a37b75/mail/components/compose/content/MsgComposeCommands.js#11222

Back to Bug 1997519 Comment 10