mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 04:47:35 +00:00
LibJS: Convert coerce_options_to_object() to ThrowCompletionOr
This commit is contained in:
parent
d0e5fc4576
commit
b9c7a629f8
4 changed files with 11 additions and 12 deletions
|
@ -360,9 +360,7 @@ NumberFormat* initialize_number_format(GlobalObject& global_object, NumberFormat
|
|||
auto requested_locales = TRY_OR_DISCARD(canonicalize_locale_list(global_object, locales_value));
|
||||
|
||||
// 2. Set options to ? CoerceOptionsToObject(options).
|
||||
auto* options = coerce_options_to_object(global_object, options_value);
|
||||
if (vm.exception())
|
||||
return {};
|
||||
auto* options = TRY_OR_DISCARD(coerce_options_to_object(global_object, options_value));
|
||||
|
||||
// 3. Let opt be a new Record.
|
||||
LocaleOptions opt {};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue