LibWeb: User getter+setter for HTMLToken tag name and self-closing flag

This commit is contained in:
Max Wipfli 2021-07-14 23:37:48 +02:00 committed by Ali Mohammad Pur
parent 1aeafcc58b
commit 15d8635afc
Notes: sideshowbarker 2024-07-18 08:52:58 +09:00
4 changed files with 34 additions and 22 deletions

View file

@ -1570,7 +1570,7 @@ void HTMLDocumentParser::handle_in_body(HTMLToken& token)
if (token.is_start_tag() && token.tag_name() == HTML::TagNames::image) {
// Parse error. Change the token's tag name to HTML::TagNames::img and reprocess it. (Don't ask.)
log_parse_error();
token.m_tag.tag_name = "img";
token.set_tag_name("img");
process_using_the_rules_for(m_insertion_mode, token);
return;
}