1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 10:38:11 +00:00

LibWeb: Make factory method of DOM::AccessibilityTreeNode fallible

This commit is contained in:
Kenneth Myhra 2023-02-14 21:30:11 +01:00 committed by Linus Groh
parent 2c8a689390
commit 1e03aa0ece
4 changed files with 6 additions and 6 deletions

View file

@ -13,9 +13,9 @@
namespace Web::DOM {
JS::NonnullGCPtr<AccessibilityTreeNode> AccessibilityTreeNode::create(Document* document, DOM::Node const* value)
WebIDL::ExceptionOr<JS::NonnullGCPtr<AccessibilityTreeNode>> AccessibilityTreeNode::create(Document* document, DOM::Node const* value)
{
return *document->heap().allocate<AccessibilityTreeNode>(document->realm(), value).release_allocated_value_but_fixme_should_propagate_errors();
return MUST_OR_THROW_OOM(document->heap().allocate<AccessibilityTreeNode>(document->realm(), value));
}
AccessibilityTreeNode::AccessibilityTreeNode(JS::GCPtr<DOM::Node> value)