1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 07:18:11 +00:00

LibJS: Convert define_property_or_throw() to ThrowCompletionOr

This commit is contained in:
Linus Groh 2021-10-03 01:35:36 +01:00
parent ebf57df431
commit fe86b04b42
12 changed files with 31 additions and 58 deletions

View file

@ -152,7 +152,7 @@ Value PromiseAnyRejectElementFunction::resolve_element()
auto errors_array = Array::create_from(global_object, m_values.values());
auto* error = AggregateError::create(global_object);
error->define_property_or_throw(vm.names.errors, { .value = errors_array, .writable = true, .enumerable = false, .configurable = true });
MUST(error->define_property_or_throw(vm.names.errors, { .value = errors_array, .writable = true, .enumerable = false, .configurable = true }));
return TRY_OR_DISCARD(vm.call(*m_capability.reject, js_undefined(), error));
}