We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 154b760 commit e62c9f3Copy full SHA for e62c9f3
src/api/dispatcher.cc
@@ -217,8 +217,10 @@ void Dispatcher::willHandleNavigationPolicy(
217
v8::HandleScope handleScope(isolate);
218
219
v8::Handle<v8::Value> id_val;
220
- if (web_view->mainFrame() && !web_view->mainFrame()->mainWorldScriptContext().IsEmpty())
+ if (web_view->mainFrame() && !web_view->mainFrame()->mainWorldScriptContext().IsEmpty()) {
221
+ v8::Context::Scope cscope (web_view->mainFrame()->mainWorldScriptContext());
222
id_val = nwapi::Dispatcher::GetWindowId(web_view->mainFrame());
223
+ }
224
if (id_val.IsEmpty())
225
return;
226
if (id_val->IsUndefined() || id_val->IsNull())
0 commit comments