| Index: third_party/WebKit/Source/core/dom/Document.cpp
|
| diff --git a/third_party/WebKit/Source/core/dom/Document.cpp b/third_party/WebKit/Source/core/dom/Document.cpp
|
| index 45a91520ec31434010ac96e70b77e51e429b7f9c..a0fd00b8116dd87ad31cb2a659c94249c9dc9148 100644
|
| --- a/third_party/WebKit/Source/core/dom/Document.cpp
|
| +++ b/third_party/WebKit/Source/core/dom/Document.cpp
|
| @@ -4772,7 +4772,8 @@ void Document::finishedParsing()
|
| // Ensure Custom Element callbacks are drained before DOMContentLoaded.
|
| // FIXME: Remove this ad-hoc checkpoint when DOMContentLoaded is dispatched in a
|
| // queued task, which will do a checkpoint anyway. https://crbug.com/425790
|
| - Microtask::performCheckpoint(V8PerIsolateData::mainThreadIsolate());
|
| + if (!V8PerIsolateData::mainThreadIsolate()->InContext())
|
| + Microtask::performCheckpoint(V8PerIsolateData::mainThreadIsolate());
|
|
|
| if (LocalFrame* frame = this->frame()) {
|
| // Don't update the layout tree if we haven't requested the main resource yet to avoid
|
|
|