1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 14:07:46 +00:00

LibWeb: Make factory methods of UIEvents::KeyboardEvent fallible

This commit is contained in:
Kenneth Myhra 2023-02-19 10:25:32 +01:00 committed by Andreas Kling
parent b91d599177
commit a401cff4e2
4 changed files with 13 additions and 13 deletions

View file

@ -1296,7 +1296,7 @@ WebIDL::ExceptionOr<JS::NonnullGCPtr<Event>> Document::create_event(DeprecatedSt
} else if (Infra::is_ascii_case_insensitive_match(interface, "htmlevents"sv)) {
event = TRY(Event::create(realm, ""));
} else if (Infra::is_ascii_case_insensitive_match(interface, "keyboardevent"sv)) {
event = UIEvents::KeyboardEvent::create(realm, "");
event = TRY(UIEvents::KeyboardEvent::create(realm, ""));
} else if (Infra::is_ascii_case_insensitive_match(interface, "messageevent"sv)) {
event = TRY(HTML::MessageEvent::create(realm, ""));
} else if (Infra::is_ascii_case_insensitive_match(interface, "mouseevent"sv)