mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-05 15:49:11 +00:00
LibWeb: Use verify_cast
in insertParagraph command
No functional changes.
This commit is contained in:
parent
1c55153d43
commit
bfb87b24a3
Notes:
github-actions[bot]
2024-12-10 13:55:30 +00:00
Author: https://github.com/gmta
Commit: bfb87b24a3
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/2844
1 changed files with 1 additions and 2 deletions
|
@ -599,8 +599,7 @@ bool command_insert_paragraph_action(DOM::Document& document, String const&)
|
|||
|| ((new_line_range->start_container() == new_line_range->end_container() && new_line_range->start_offset() == new_line_range->end_offset() - 1)
|
||||
&& is<HTML::HTMLBRElement>(*new_line_range->start_container()));
|
||||
|
||||
VERIFY(is<DOM::Element>(*container));
|
||||
auto& container_element = static_cast<DOM::Element&>(*container);
|
||||
auto& container_element = verify_cast<DOM::Element>(*container);
|
||||
auto new_container_name = [&] -> FlyString {
|
||||
// 18. If the local name of container is "h1", "h2", "h3", "h4", "h5", or "h6", and end of line is true, let new
|
||||
// container name be the default single-line container name.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue