Thursday, February 8, 2024
1 change · 17.0
Resolved issues and error corrections
This fix resolves a crash that occurred when users tried to add content blocks to email marketing campaigns. The issue happened because the system was trying to access properties of an empty selection when blocks were dropped into the email editor. Users can now successfully add blocks to their mailings without encountering errors.
Original PR description
Issue: ====== Adding a new block in mailing in email marketing raises an error. Steps to reproduce the issue: ============================= - Go to email marketing - Create a new mailing - Create one from scratch - Drop any block - `TypeError : Cannor read properties of null (reading 'parentElement')` Origin of the issue: ==================== When we drop the block in the iframe's document we trigger the `click` event but we don't have any selection yet in the document so `anchorNode`will be `null` thus the error. task-3724551