mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-01-04 15:45:25 +00:00
LibJS: Convert Array AOs to ThrowCompletionOr
This commit is contained in:
@@ -428,7 +428,7 @@ Object* JSONObject::parse_json_object(GlobalObject& global_object, const JsonObj
|
||||
|
||||
Array* JSONObject::parse_json_array(GlobalObject& global_object, const JsonArray& json_array)
|
||||
{
|
||||
auto* array = Array::create(global_object, 0);
|
||||
auto* array = MUST(Array::create(global_object, 0));
|
||||
size_t index = 0;
|
||||
json_array.for_each([&](auto& value) {
|
||||
array->define_direct_property(index++, parse_json_value(global_object, value), JS::default_attributes);
|
||||
|
||||
Reference in New Issue
Block a user