mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-06-17 15:51:55 +00:00
LibWeb: Return DOMException instead of crashing when setting attributes
This commit is contained in:
parent
6891676fce
commit
5d3b7a5ecc
Notes:
sideshowbarker
2024-07-16 19:42:24 +09:00
Author: https://github.com/PrestonLTaylor
Commit: 5d3b7a5ecc
Pull-request: https://github.com/SerenityOS/serenity/pull/19044
24 changed files with 57 additions and 51 deletions
|
@ -78,9 +78,9 @@ DeprecatedString HTMLOptionElement::value() const
|
|||
}
|
||||
|
||||
// https://html.spec.whatwg.org/multipage/form-elements.html#dom-option-value
|
||||
void HTMLOptionElement::set_value(DeprecatedString value)
|
||||
WebIDL::ExceptionOr<void> HTMLOptionElement::set_value(DeprecatedString value)
|
||||
{
|
||||
MUST(set_attribute(HTML::AttributeNames::value, value));
|
||||
return set_attribute(HTML::AttributeNames::value, value);
|
||||
}
|
||||
|
||||
static void concatenate_descendants_text_content(DOM::Node const* node, StringBuilder& builder)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue