mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-26 03:09:08 +00:00
LibJS: Start implementing a Console class for the interpreter
The goal is to start factoring out core ConsoleObject functionality and to make ConsoleObject only a JS wrapper around Console.
This commit is contained in:
committed by
Andreas Kling
parent
745b0b27fd
commit
2e92c2e5e1
@@ -121,7 +121,7 @@ Value ConsoleObject::count(Interpreter& interpreter)
|
||||
else
|
||||
counter_name = interpreter.argument(0).to_string();
|
||||
|
||||
auto& counters = interpreter.console_counters();
|
||||
auto& counters = interpreter.console().counters();
|
||||
auto counter_value = counters.get(counter_name);
|
||||
|
||||
if (counter_value.has_value()) {
|
||||
@@ -142,7 +142,7 @@ Value ConsoleObject::count_reset(Interpreter& interpreter)
|
||||
else
|
||||
counter_name = interpreter.argument(0).to_string();
|
||||
|
||||
auto& counters = interpreter.console_counters();
|
||||
auto& counters = interpreter.console().counters();
|
||||
|
||||
if (counters.contains(counter_name)) {
|
||||
counters.remove(counter_name);
|
||||
|
||||
Reference in New Issue
Block a user