summaryrefslogtreecommitdiff
path: root/Userland/Services/WebContent
diff options
context:
space:
mode:
authorAndreas Kling <kling@serenityos.org>2022-04-05 17:47:52 +0200
committerAndreas Kling <kling@serenityos.org>2022-04-05 17:47:52 +0200
commit217993b1d100f6ce1f0eead29ba8d1b24d358d54 (patch)
treeac0b1f71b0346c99353cb1cf34f5fb7e2a2f5278 /Userland/Services/WebContent
parent1a38ab0ca158f1a4fd22fccd3b1cbbd795d41249 (diff)
downloadserenity-217993b1d100f6ce1f0eead29ba8d1b24d358d54.zip
Revert "WebContent: Use ConsoleGlobalObject for the console's global object :^)"
This reverts commit 8296dd995562a0233dcc75d4f59621f60dd0c77d.
Diffstat (limited to 'Userland/Services/WebContent')
-rw-r--r--Userland/Services/WebContent/WebContentConsoleClient.cpp2
-rw-r--r--Userland/Services/WebContent/WebContentConsoleClient.h1
2 files changed, 2 insertions, 1 deletions
diff --git a/Userland/Services/WebContent/WebContentConsoleClient.cpp b/Userland/Services/WebContent/WebContentConsoleClient.cpp
index 1b245b6918..fb742e9a38 100644
--- a/Userland/Services/WebContent/WebContentConsoleClient.cpp
+++ b/Userland/Services/WebContent/WebContentConsoleClient.cpp
@@ -35,7 +35,7 @@ WebContentConsoleClient::WebContentConsoleClient(JS::Console& console, WeakPtr<J
console_global_object->initialize_global_object();
vm.pop_execution_context();
- m_interpreter->realm().set_global_object(*console_global_object);
+ m_console_global_object = JS::make_handle(console_global_object);
}
void WebContentConsoleClient::handle_input(String const& js_source)
diff --git a/Userland/Services/WebContent/WebContentConsoleClient.h b/Userland/Services/WebContent/WebContentConsoleClient.h
index 5ece72e9fb..9456750d55 100644
--- a/Userland/Services/WebContent/WebContentConsoleClient.h
+++ b/Userland/Services/WebContent/WebContentConsoleClient.h
@@ -29,6 +29,7 @@ private:
ConnectionFromClient& m_client;
WeakPtr<JS::Interpreter> m_interpreter;
+ JS::Handle<ConsoleGlobalObject> m_console_global_object;
void clear_output();
void print_html(String const& line);