diff options
Diffstat (limited to 'Userland')
7 files changed, 12 insertions, 12 deletions
diff --git a/Userland/Libraries/LibWeb/Bindings/WindowObject.cpp b/Userland/Libraries/LibWeb/Bindings/WindowObject.cpp index 12e53f949a..c6c764651f 100644 --- a/Userland/Libraries/LibWeb/Bindings/WindowObject.cpp +++ b/Userland/Libraries/LibWeb/Bindings/WindowObject.cpp @@ -133,7 +133,7 @@ static DOM::Window* impl_from(JS::VM& vm, JS::GlobalObject& global_object) VERIFY(this_object); if (StringView("WindowObject") != this_object->class_name()) { - vm.throw_exception<JS::TypeError>(global_object, JS::ErrorType::NotA, "WindowObject"); + vm.throw_exception<JS::TypeError>(global_object, JS::ErrorType::NotAnObjectOfType, "WindowObject"); return nullptr; } return &static_cast<WindowObject*>(this_object)->impl(); @@ -463,7 +463,7 @@ JS_DEFINE_NATIVE_FUNCTION(WindowObject::get_computed_style) return {}; if (!is<ElementWrapper>(object)) { - vm.throw_exception<JS::TypeError>(global_object, JS::ErrorType::NotA, "DOM element"); + vm.throw_exception<JS::TypeError>(global_object, JS::ErrorType::NotAnObjectOfType, "DOM element"); return {}; } diff --git a/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyInstanceConstructor.cpp b/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyInstanceConstructor.cpp index 94953c0342..770249be7f 100644 --- a/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyInstanceConstructor.cpp +++ b/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyInstanceConstructor.cpp @@ -39,7 +39,7 @@ JS::Value WebAssemblyInstanceConstructor::construct(FunctionObject&) return {}; if (!is<WebAssemblyModuleObject>(module_argument)) { - vm.throw_exception<JS::TypeError>(global_object, JS::ErrorType::NotA, "WebAssembly.Module"); + vm.throw_exception<JS::TypeError>(global_object, JS::ErrorType::NotAnObjectOfType, "WebAssembly.Module"); return {}; } diff --git a/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyInstanceObjectPrototype.cpp b/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyInstanceObjectPrototype.cpp index 8b37f813de..924a6c1102 100644 --- a/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyInstanceObjectPrototype.cpp +++ b/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyInstanceObjectPrototype.cpp @@ -23,7 +23,7 @@ JS_DEFINE_NATIVE_FUNCTION(WebAssemblyInstancePrototype::exports_getter) if (vm.exception()) return {}; if (!is<WebAssemblyInstanceObject>(this_object)) { - vm.throw_exception<JS::TypeError>(global_object, JS::ErrorType::NotA, "WebAssembly.Instance"); + vm.throw_exception<JS::TypeError>(global_object, JS::ErrorType::NotAnObjectOfType, "WebAssembly.Instance"); return {}; } auto object = static_cast<WebAssemblyInstanceObject*>(this_object); diff --git a/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyMemoryConstructor.cpp b/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyMemoryConstructor.cpp index 338dbcc959..deb27bd3bf 100644 --- a/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyMemoryConstructor.cpp +++ b/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyMemoryConstructor.cpp @@ -40,7 +40,7 @@ JS::Value WebAssemblyMemoryConstructor::construct(FunctionObject&) auto maximum_value = descriptor->get_without_side_effects("maximum"); if (initial_value.is_empty()) { - vm.throw_exception<JS::TypeError>(global_object, JS::ErrorType::NotA, "Number"); + vm.throw_exception<JS::TypeError>(global_object, JS::ErrorType::NotAnObjectOfType, "Number"); return {}; } diff --git a/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyMemoryPrototype.cpp b/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyMemoryPrototype.cpp index 0655cdcc3a..1033bb8268 100644 --- a/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyMemoryPrototype.cpp +++ b/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyMemoryPrototype.cpp @@ -24,7 +24,7 @@ JS_DEFINE_NATIVE_FUNCTION(WebAssemblyMemoryPrototype::grow) return {}; auto* this_object = vm.this_value(global_object).to_object(global_object); if (!this_object || !is<WebAssemblyMemoryObject>(this_object)) { - vm.throw_exception<JS::TypeError>(global_object, JS::ErrorType::NotA, "WebAssembly.Memory"); + vm.throw_exception<JS::TypeError>(global_object, JS::ErrorType::NotAnObjectOfType, "WebAssembly.Memory"); return {}; } auto* memory_object = static_cast<WebAssemblyMemoryObject*>(this_object); @@ -46,7 +46,7 @@ JS_DEFINE_NATIVE_FUNCTION(WebAssemblyMemoryPrototype::buffer_getter) { auto* this_object = vm.this_value(global_object).to_object(global_object); if (!this_object || !is<WebAssemblyMemoryObject>(this_object)) { - vm.throw_exception<JS::TypeError>(global_object, JS::ErrorType::NotA, "WebAssembly.Memory"); + vm.throw_exception<JS::TypeError>(global_object, JS::ErrorType::NotAnObjectOfType, "WebAssembly.Memory"); return {}; } auto* memory_object = static_cast<WebAssemblyMemoryObject*>(this_object); diff --git a/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyObject.cpp b/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyObject.cpp index aabe0d27c6..1f1459ef9a 100644 --- a/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyObject.cpp +++ b/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyObject.cpp @@ -428,7 +428,7 @@ Optional<Wasm::Value> to_webassembly_value(JS::Value value, const Wasm::ValueTyp } } - vm.throw_exception<JS::TypeError>(global_object, JS::ErrorType::NotAn, "Exported function"); + vm.throw_exception<JS::TypeError>(global_object, JS::ErrorType::NotAnObjectOfType, "Exported function"); return {}; } case Wasm::ValueType::ExternReference: diff --git a/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyTablePrototype.cpp b/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyTablePrototype.cpp index 161d413fdf..614c132228 100644 --- a/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyTablePrototype.cpp +++ b/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyTablePrototype.cpp @@ -26,7 +26,7 @@ JS_DEFINE_NATIVE_FUNCTION(WebAssemblyTablePrototype::grow) return {}; auto* this_object = vm.this_value(global_object).to_object(global_object); if (!this_object || !is<WebAssemblyTableObject>(this_object)) { - vm.throw_exception<JS::TypeError>(global_object, JS::ErrorType::NotA, "WebAssembly.Table"); + vm.throw_exception<JS::TypeError>(global_object, JS::ErrorType::NotAnObjectOfType, "WebAssembly.Table"); return {}; } auto* table_object = static_cast<WebAssemblyTableObject*>(this_object); @@ -65,7 +65,7 @@ JS_DEFINE_NATIVE_FUNCTION(WebAssemblyTablePrototype::get) auto* this_object = vm.this_value(global_object).to_object(global_object); if (!this_object || !is<WebAssemblyTableObject>(this_object)) { - vm.throw_exception<JS::TypeError>(global_object, JS::ErrorType::NotA, "WebAssembly.Table"); + vm.throw_exception<JS::TypeError>(global_object, JS::ErrorType::NotAnObjectOfType, "WebAssembly.Table"); return {}; } auto* table_object = static_cast<WebAssemblyTableObject*>(this_object); @@ -95,7 +95,7 @@ JS_DEFINE_NATIVE_FUNCTION(WebAssemblyTablePrototype::set) auto* this_object = vm.this_value(global_object).to_object(global_object); if (!this_object || !is<WebAssemblyTableObject>(this_object)) { - vm.throw_exception<JS::TypeError>(global_object, JS::ErrorType::NotA, "WebAssembly.Table"); + vm.throw_exception<JS::TypeError>(global_object, JS::ErrorType::NotAnObjectOfType, "WebAssembly.Table"); return {}; } auto* table_object = static_cast<WebAssemblyTableObject*>(this_object); @@ -130,7 +130,7 @@ JS_DEFINE_NATIVE_FUNCTION(WebAssemblyTablePrototype::length_getter) { auto* this_object = vm.this_value(global_object).to_object(global_object); if (!this_object || !is<WebAssemblyTableObject>(this_object)) { - vm.throw_exception<JS::TypeError>(global_object, JS::ErrorType::NotA, "WebAssembly.Table"); + vm.throw_exception<JS::TypeError>(global_object, JS::ErrorType::NotAnObjectOfType, "WebAssembly.Table"); return {}; } auto* table_object = static_cast<WebAssemblyTableObject*>(this_object); |