diff options
Diffstat (limited to 'Userland/Libraries/LibWeb/DOM')
-rw-r--r-- | Userland/Libraries/LibWeb/DOM/Document.cpp | 2 | ||||
-rw-r--r-- | Userland/Libraries/LibWeb/DOM/EventTarget.cpp | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/Userland/Libraries/LibWeb/DOM/Document.cpp b/Userland/Libraries/LibWeb/DOM/Document.cpp index 317fb3163d..e2c5ca2c0d 100644 --- a/Userland/Libraries/LibWeb/DOM/Document.cpp +++ b/Userland/Libraries/LibWeb/DOM/Document.cpp @@ -1087,7 +1087,7 @@ Color Document::visited_link_color() const HTML::EnvironmentSettingsObject& Document::relevant_settings_object() { // Then, the relevant settings object for a platform object o is the environment settings object of the relevant Realm for o. - return verify_cast<HTML::EnvironmentSettingsObject>(*realm().host_defined()); + return Bindings::host_defined_environment_settings_object(realm()); } JS::Value Document::run_javascript(StringView source, StringView filename) diff --git a/Userland/Libraries/LibWeb/DOM/EventTarget.cpp b/Userland/Libraries/LibWeb/DOM/EventTarget.cpp index df1b6855ef..244cad529e 100644 --- a/Userland/Libraries/LibWeb/DOM/EventTarget.cpp +++ b/Userland/Libraries/LibWeb/DOM/EventTarget.cpp @@ -556,7 +556,7 @@ void EventTarget::activate_event_handler(FlyString const& name, HTML::EventHandl 0, "", &realm); // NOTE: As per the spec, the callback context is arbitrary. - auto* callback = realm.heap().allocate_without_realm<WebIDL::CallbackType>(*callback_function, verify_cast<HTML::EnvironmentSettingsObject>(*realm.host_defined())); + auto* callback = realm.heap().allocate_without_realm<WebIDL::CallbackType>(*callback_function, Bindings::host_defined_environment_settings_object(realm)); // 5. Let listener be a new event listener whose type is the event handler event type corresponding to eventHandler and callback is callback. auto* listener = realm.heap().allocate_without_realm<DOMEventListener>(); |