Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[FIX] html_editor: traceback when pressing enter in unsplittable block
Steps to Reproduce: 1. Navigate to Project. 2. Open Studio and go to Reports -> Timesheets Report. 3. Place the cursor before the text "Expression" and press Enter. 4. Next, place the cursor before the text "Name" and press Enter. 5. A traceback occurs. Before this commit: When pressing Enter with the cursor inside an unsplittable block, instead of creating a new tag, the `insertLineBreakElement`is called which adds a `<br>` and returns `undefined`. Consequently, in `handleSplitBlockHeading`, `newElement` is `undefined`, leading to a traceback when attempting to access its `tagName`. After this commit: The traceback no longer occurs when pressing Enter in an unsplittable block. task-4334925 closes odoo#188905 X-original-commit: ef976bd Signed-off-by: David Monjoie (dmo) <[email protected]> Signed-off-by: Adnan Chaudhary (adch) <[email protected]>
- Loading branch information