Skip to content

Commit

Permalink
src: call overload ctor from the original ctor
Browse files Browse the repository at this point in the history
Call the new constructor overload from the original constructor to
reduce code duplication.

Signed-off-by: Darshan Sen <darshan.sen@postman.com>

PR-URL: #39768
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com>
  • Loading branch information
RaisinTen authored and targos committed Sep 4, 2021
1 parent 1efae01 commit abfd71b
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions src/api/callback.cc
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,8 @@ using v8::Value;

CallbackScope::CallbackScope(Isolate* isolate,
Local<Object> object,
async_context asyncContext)
: private_(new InternalCallbackScope(Environment::GetCurrent(isolate),
object,
asyncContext)),
try_catch_(isolate) {
try_catch_.SetVerbose(true);
}
async_context async_context)
: CallbackScope(Environment::GetCurrent(isolate), object, async_context) {}

CallbackScope::CallbackScope(Environment* env,
Local<Object> object,
Expand Down

0 comments on commit abfd71b

Please sign in to comment.