mirror of
https://github.com/electron/electron.git
synced 2026-01-09 15:38:08 -05:00
refactor: avoid deprecated v8::Context::GetIsolate() calls (pt 2) (#47879)
* refactor: add a v8::Isolate* arg to Constructible::GetConstructor() * refactor: add a v8::Isolate* arg to NodeBindings::Initialize() This is needed for the GetConstructor() call * refactor: avoid v8::Context::GetIsolate() call in GetIpcObject() by taking it as an arg * refactor: avoid v8::Context::GetIsolate() call in ipc_native::EmitIPCEvent() by taking it as an arg
This commit is contained in:
@@ -356,7 +356,8 @@ void Initialize(v8::Local<v8::Object> exports,
|
||||
void* priv) {
|
||||
v8::Isolate* const isolate = electron::JavascriptEnvironment::GetIsolate();
|
||||
gin_helper::Dictionary dict{isolate, exports};
|
||||
dict.Set("ServiceWorkerMain", ServiceWorkerMain::GetConstructor(context));
|
||||
dict.Set("ServiceWorkerMain",
|
||||
ServiceWorkerMain::GetConstructor(isolate, context));
|
||||
}
|
||||
|
||||
} // namespace
|
||||
|
||||
Reference in New Issue
Block a user