mirror of
https://github.com/electron/electron.git
synced 2026-04-10 03:01:51 -04:00
Run microtask before handling pending process.nextTick tasks
This follows the behavior of Node.js.
This commit is contained in:
@@ -98,6 +98,10 @@ void AtomBindings::OnCallNextTick(uv_async_t* handle) {
|
||||
if (tick_info->in_tick())
|
||||
continue;
|
||||
|
||||
if (tick_info->length() == 0) {
|
||||
env->isolate()->RunMicrotasks();
|
||||
}
|
||||
|
||||
if (tick_info->length() == 0) {
|
||||
tick_info->set_index(0);
|
||||
continue;
|
||||
|
||||
Reference in New Issue
Block a user