Skip to content

Commit

Permalink
src: return Maybe from a couple of functions
Browse files Browse the repository at this point in the history
  • Loading branch information
codebytere committed Nov 8, 2022
1 parent f133df7 commit 6c679f7
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions shell/renderer/electron_renderer_client.cc
Original file line number Diff line number Diff line change
Expand Up @@ -85,8 +85,8 @@ void ElectronRendererClient::DidCreateScriptContext(
node::tracing::TraceEventHelper::SetAgent(node::CreateAgent());

// Setup node environment for each window.
bool initialized = node::InitializeContext(renderer_context);
CHECK(initialized);
v8::Maybe<bool> initialized = node::InitializeContext(renderer_context);
CHECK(!initialized.IsNothing());

node::Environment* env =
node_bindings_->CreateEnvironment(renderer_context, nullptr);
Expand Down
4 changes: 2 additions & 2 deletions shell/renderer/web_worker_observer.cc
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,8 @@ void WebWorkerObserver::WorkerScriptReadyForEvaluation(
node::tracing::TraceEventHelper::SetAgent(node::CreateAgent());

// Setup node environment for each window.
bool initialized = node::InitializeContext(worker_context);
CHECK(initialized);
v8::Maybe<bool> initialized = node::InitializeContext(worker_context);
CHECK(!initialized.IsNothing());
node::Environment* env =
node_bindings_->CreateEnvironment(worker_context, nullptr);

Expand Down

0 comments on commit 6c679f7

Please sign in to comment.