mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-01 05:39:11 +00:00
LibWeb: Make factory method of Selection::Selection fallible
This commit is contained in:
parent
d69e863286
commit
dcbe927b48
Notes:
sideshowbarker
2024-07-17 09:39:38 +09:00
Author: https://github.com/kennethmyhra
Commit: dcbe927b48
Pull-request: https://github.com/SerenityOS/serenity/pull/17542
3 changed files with 4 additions and 4 deletions
|
@ -11,9 +11,9 @@
|
|||
|
||||
namespace Web::Selection {
|
||||
|
||||
JS::NonnullGCPtr<Selection> Selection::create(JS::NonnullGCPtr<JS::Realm> realm, JS::NonnullGCPtr<DOM::Document> document)
|
||||
WebIDL::ExceptionOr<JS::NonnullGCPtr<Selection>> Selection::create(JS::NonnullGCPtr<JS::Realm> realm, JS::NonnullGCPtr<DOM::Document> document)
|
||||
{
|
||||
return realm->heap().allocate<Selection>(realm, realm, document).release_allocated_value_but_fixme_should_propagate_errors();
|
||||
return MUST_OR_THROW_OOM(realm->heap().allocate<Selection>(realm, realm, document));
|
||||
}
|
||||
|
||||
Selection::Selection(JS::NonnullGCPtr<JS::Realm> realm, JS::NonnullGCPtr<DOM::Document> document)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue