diff options
author | Linus Groh <mail@linusgroh.de> | 2020-04-13 16:21:54 +0100 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2020-04-14 13:40:04 +0200 |
commit | 9fab52a39021c9d42c455e8165e4e30c8b408f57 (patch) | |
tree | 9dc593c74741bf5051d7974bcf5c1c56b5e1ed63 /Libraries/LibWeb | |
parent | d74ad81402c27113b2ed5586bc369703d6be61c4 (diff) | |
download | serenity-9fab52a39021c9d42c455e8165e4e30c8b408f57.zip |
LibJS: Remove shift, pop, push functions from Array object
This abstraction isn't really that useful, as we can access the
underlying Vector<Value> using elements() and operate on it directly.
Diffstat (limited to 'Libraries/LibWeb')
-rw-r--r-- | Libraries/LibWeb/Bindings/DocumentWrapper.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Libraries/LibWeb/Bindings/DocumentWrapper.cpp b/Libraries/LibWeb/Bindings/DocumentWrapper.cpp index 9a5bcb60c5..df9c84dcb2 100644 --- a/Libraries/LibWeb/Bindings/DocumentWrapper.cpp +++ b/Libraries/LibWeb/Bindings/DocumentWrapper.cpp @@ -98,7 +98,7 @@ JS::Value DocumentWrapper::query_selector_all(JS::Interpreter& interpreter) // FIXME: This should be a static NodeList, not a plain JS::Array. auto* node_list = interpreter.heap().allocate<JS::Array>(); for (auto& element : elements) { - node_list->push(wrap(interpreter.heap(), element)); + node_list->elements().append(wrap(interpreter.heap(), element)); } return node_list; } |