Skip to content

Commit

Permalink
remove src_expose_maybeinitializecontext_to_allow_existing_contexts.p…
Browse files Browse the repository at this point in the history
  • Loading branch information
codebytere committed Sep 23, 2019
1 parent 508de85 commit 1baf5bf
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 55 deletions.
1 change: 0 additions & 1 deletion patches/node/.patches
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@ chore_allow_the_node_entrypoint_to_be_a_builtin_module.patch
inherit_electron_crashpad_pipe_name_in_child_process.patch
fixme_revert_crypto_add_support_for_rsa-pss_keys.patch
chore_re-add_compileandcall_this_should_be_added_as_a_helper_in.patch
src_expose_maybeinitializecontext_to_allow_existing_contexts.patch
fix_extern_the_nativemoduleenv_and_options_parser_for_debug_builds.patch
chore_read_nobrowserglobals_from_global_not_process.patch
chore_split_createenvironment_into_createenvironment_and.patch
Expand Down

This file was deleted.

7 changes: 3 additions & 4 deletions shell/renderer/atom_renderer_client.cc
Original file line number Diff line number Diff line change
Expand Up @@ -121,11 +121,10 @@ void AtomRendererClient::DidCreateScriptContext(
node::tracing::TraceEventHelper::SetAgent(node::CreateAgent());

// Setup node environment for each window.
v8::Local<v8::Context> context =
node::MaybeInitializeContext(renderer_context);
DCHECK(!context.IsEmpty());
DCHECK(node::InitializeContext(renderer_context));
node::Environment* env =
node_bindings_->CreateEnvironment(context, nullptr, true);
node_bindings_->CreateEnvironment(renderer_context, nullptr, true);

// If we have disabled the site instance overrides we should prevent loading
// any non-context aware native module
if (command_line->HasSwitch(switches::kDisableElectronSiteInstanceOverrides))
Expand Down
5 changes: 2 additions & 3 deletions shell/renderer/web_worker_observer.cc
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 +48,9 @@ void WebWorkerObserver::ContextCreated(v8::Local<v8::Context> worker_context) {
node_bindings_->PrepareMessageLoop();

// Setup node environment for each window.
v8::Local<v8::Context> context = node::MaybeInitializeContext(worker_context);
DCHECK(!context.IsEmpty());
DCHECK(node::InitializeContext(worker_context));
node::Environment* env =
node_bindings_->CreateEnvironment(context, nullptr, true);
node_bindings_->CreateEnvironment(worker_context, nullptr, true);

// Add Electron extended APIs.
electron_bindings_->BindTo(env->isolate(), env->process_object());
Expand Down

0 comments on commit 1baf5bf

Please sign in to comment.