diff options
Diffstat (limited to 'ext/timers/01_timers.js')
-rw-r--r-- | ext/timers/01_timers.js | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/ext/timers/01_timers.js b/ext/timers/01_timers.js index caa490e61..a0b1deb45 100644 --- a/ext/timers/01_timers.js +++ b/ext/timers/01_timers.js @@ -17,6 +17,7 @@ NumberPOSITIVE_INFINITY, PromisePrototypeThen, ObjectPrototypeIsPrototypeOf, + SafeArrayIterator, SymbolFor, TypeError, } = window.__bootstrap.primordials; @@ -159,7 +160,11 @@ // 3. // TODO(@andreubotella): Error handling. if (typeof callback === "function") { - FunctionPrototypeCall(callback, globalThis, ...args); + FunctionPrototypeCall( + callback, + globalThis, + ...new SafeArrayIterator(args), + ); } else { // TODO(@andreubotella): eval doesn't seem to have a primordial, but // it can be redefined in the global scope. |