Skip to content

Commit abfd71b

Browse files
RaisinTentargos
authored andcommitted
src: call overload ctor from the original ctor
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>
1 parent 1efae01 commit abfd71b

File tree

1 file changed

+2
-7
lines changed

1 file changed

+2
-7
lines changed

src/api/callback.cc

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -19,13 +19,8 @@ using v8::Value;
1919

2020
CallbackScope::CallbackScope(Isolate* isolate,
2121
Local<Object> object,
22-
async_context asyncContext)
23-
: private_(new InternalCallbackScope(Environment::GetCurrent(isolate),
24-
object,
25-
asyncContext)),
26-
try_catch_(isolate) {
27-
try_catch_.SetVerbose(true);
28-
}
22+
async_context async_context)
23+
: CallbackScope(Environment::GetCurrent(isolate), object, async_context) {}
2924

3025
CallbackScope::CallbackScope(Environment* env,
3126
Local<Object> object,

0 commit comments

Comments
 (0)