[inspector] run microtasks after async Runtime.evaluate
If promise was resolved before adding handler in Runtime.evaluate method then this callback won't be called. We need to run microtasks after adding handlers. R=dgozman@chromium.org,alph@chromium.org Review-Url: https://codereview.chromium.org/2371773004 Cr-Commit-Position: refs/heads/master@{#39793}
This commit is contained in:
parent
34922e8d77
commit
ff135975b0
@ -78,6 +78,8 @@ class ProtocolPromiseHandler {
|
||||
callback->sendFailure(notPromiseError);
|
||||
return;
|
||||
}
|
||||
v8::MicrotasksScope microtasks_scope(inspector->isolate(),
|
||||
v8::MicrotasksScope::kRunMicrotasks);
|
||||
v8::Local<v8::Promise> promise =
|
||||
v8::Local<v8::Promise>::Cast(value.ToLocalChecked());
|
||||
Callback* rawCallback = callback.get();
|
||||
|
Loading…
Reference in New Issue
Block a user