1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-20 17:25:08 +00:00

LibWeb: Port the WindowOrWorkerGlobalScopeMixin timer handler to String

This will make porting to IDL a bit cleaner.
This commit is contained in:
Timothy Flynn 2023-03-14 07:06:32 -04:00 committed by Tim Flynn
parent dd992e7dad
commit 2895b7e733
3 changed files with 3 additions and 3 deletions

View file

@ -1370,7 +1370,7 @@ static JS::ThrowCompletionOr<TimerHandler> make_timer_handler(JS::VM& vm, JS::Va
{
if (handler.is_function())
return JS::make_handle(vm.heap().allocate_without_realm<WebIDL::CallbackType>(handler.as_function(), incumbent_settings_object()));
return TRY(handler.to_deprecated_string(vm));
return TRY(handler.to_string(vm));
}
// https://html.spec.whatwg.org/multipage/timers-and-user-prompts.html#dom-settimeout