summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibWeb
diff options
context:
space:
mode:
authorLinus Groh <mail@linusgroh.de>2021-10-09 12:32:26 +0100
committerLinus Groh <mail@linusgroh.de>2021-10-09 12:36:28 +0100
commit5b61b60bbd72c18d2b4c32f04bec0181b9c71471 (patch)
treec463131217ff16d120aa69c877e95537ce6a521c /Userland/Libraries/LibWeb
parent1fba5ca8c370ac1c42627761ddfeb8d3557e656b (diff)
downloadserenity-5b61b60bbd72c18d2b4c32f04bec0181b9c71471.zip
LibJS: Use AllocateArrayBuffer where the spec tells us to
Diffstat (limited to 'Userland/Libraries/LibWeb')
-rw-r--r--Userland/Libraries/LibWeb/WebAssembly/WebAssemblyMemoryPrototype.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyMemoryPrototype.cpp b/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyMemoryPrototype.cpp
index 1033bb8268..461e5b4ff9 100644
--- a/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyMemoryPrototype.cpp
+++ b/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyMemoryPrototype.cpp
@@ -55,7 +55,7 @@ JS_DEFINE_NATIVE_FUNCTION(WebAssemblyMemoryPrototype::buffer_getter)
if (!memory)
return JS::js_undefined();
- auto array_buffer = JS::ArrayBuffer::create(global_object, &memory->data());
+ auto array_buffer = TRY_OR_DISCARD(JS::ArrayBuffer::create(global_object, &memory->data()));
array_buffer->set_detach_key(JS::js_string(vm, "WebAssembly.Memory"));
return array_buffer;
}