mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-08 09:09:43 +00:00
LibWeb: Ensure special error event handling applies to workers
This commit is contained in:
parent
99ef078c97
commit
f807b2800e
Notes:
github-actions[bot]
2024-10-05 07:18:35 +00:00
Author: https://github.com/tcl3
Commit: f807b2800e
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/1614
Reviewed-by: https://github.com/awesomekling
1 changed files with 1 additions and 2 deletions
|
@ -646,8 +646,7 @@ JS::ThrowCompletionOr<void> EventTarget::process_event_handler_for_event(FlyStri
|
|||
|
||||
// 3. Let special error event handling be true if event is an ErrorEvent object, event's type is error, and event's currentTarget implements the WindowOrWorkerGlobalScope mixin.
|
||||
// Otherwise, let special error event handling be false.
|
||||
// FIXME: This doesn't check for WorkerGlobalScape as we don't currently have it.
|
||||
bool special_error_event_handling = is<HTML::ErrorEvent>(event) && event.type() == HTML::EventNames::error && is<HTML::Window>(event.current_target().ptr());
|
||||
bool special_error_event_handling = is<HTML::ErrorEvent>(event) && event.type() == HTML::EventNames::error && is<HTML::WindowOrWorkerGlobalScopeMixin>(event.current_target().ptr());
|
||||
|
||||
// 4. Process the Event object event as follows:
|
||||
JS::Completion return_value_or_error;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue