ignore errors thrown from deferred calls

This commit is contained in:
Dmitry Vasilev
2023-02-14 18:19:26 +08:00
parent e7d4fce372
commit 8bb4369ba5
2 changed files with 10 additions and 0 deletions

View File

@@ -326,6 +326,11 @@ const __trace = (cxt, fn, name, argscount, __location, get_closure) => {
ok = false
error = _error
set_record_call(cxt)
if(cxt.is_recording_deferred_calls && is_toplevel_call_copy) {
if(error instanceof cxt.window.Error) {
error.__ignore = true
}
}
throw error
} finally {