Skip to content

Commit

Permalink
src: use cached emit v8::String
Browse files Browse the repository at this point in the history
Signed-off-by: Daeyeon Jeong <daeyeon.dev@gmail.com>
PR-URL: #57249
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Jake Yuesong Li <jake.yuesong@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
  • Loading branch information
daeyeon authored Mar 5, 2025
1 parent e05756f commit 345aa1f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/node_process_events.cc
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,8 @@ MaybeLocal<Value> ProcessEmit(Environment* env,

Local<Object> process = env->process_object();
Local<Value> argv[] = {event_string, message};
return MakeCallback(isolate, process, "emit", arraysize(argv), argv, {0, 0});
return MakeCallback(
isolate, process, env->emit_string(), arraysize(argv), argv, {0, 0});
}

Maybe<bool> ProcessEmitWarningGeneric(Environment* env,
Expand Down

0 comments on commit 345aa1f

Please sign in to comment.