diff options
author | Idan Horowitz <idan.horowitz@gmail.com> | 2021-09-23 20:05:34 +0300 |
---|---|---|
committer | Idan Horowitz <idan.horowitz@gmail.com> | 2021-09-23 23:59:13 +0300 |
commit | 1db7e096e24f004cbc86b20c5218b394a0ef5533 (patch) | |
tree | 203f28d66dff2ef136460eabcb4a430534c8a3d9 /Userland/Libraries/LibJS/Runtime/ArrayConstructor.cpp | |
parent | 0b9e633482fcc49a14e54e6e7cdee46667135b1e (diff) | |
download | serenity-1db7e096e24f004cbc86b20c5218b394a0ef5533.zip |
LibJS: Switch is_array to ThrowCompletionOr
Diffstat (limited to 'Userland/Libraries/LibJS/Runtime/ArrayConstructor.cpp')
-rw-r--r-- | Userland/Libraries/LibJS/Runtime/ArrayConstructor.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Userland/Libraries/LibJS/Runtime/ArrayConstructor.cpp b/Userland/Libraries/LibJS/Runtime/ArrayConstructor.cpp index 52bcaa3343..4956552fee 100644 --- a/Userland/Libraries/LibJS/Runtime/ArrayConstructor.cpp +++ b/Userland/Libraries/LibJS/Runtime/ArrayConstructor.cpp @@ -213,7 +213,7 @@ JS_DEFINE_NATIVE_FUNCTION(ArrayConstructor::from) JS_DEFINE_NATIVE_FUNCTION(ArrayConstructor::is_array) { auto value = vm.argument(0); - return Value(value.is_array(global_object)); + return Value(TRY_OR_DISCARD(value.is_array(global_object))); } // 23.1.2.3 Array.of ( ...items ), https://tc39.es/ecma262/#sec-array.of |