1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 19:47:44 +00:00

LibWeb: Allow IDL attribute setters to throw DOMExceptions

This commit is contained in:
Idan Horowitz 2021-09-13 21:44:42 +03:00 committed by Andreas Kling
parent f9a169380c
commit 23997005cf

View file

@ -1727,7 +1727,7 @@ JS_DEFINE_NATIVE_FUNCTION(@prototype_class@::@attribute.setter_callback@)
}
} else {
attribute_generator.append(R"~~~(
impl->set_@attribute.name:snakecase@(cpp_value);
[[maybe_unused]] auto retval = throw_dom_exception_if_needed(vm, global_object, [&] { return impl->set_@attribute.name:snakecase@(cpp_value); });
)~~~");
}