diff options
author | Daniel Bevenius <daniel.bevenius@gmail.com> | 2020-05-12 14:31:46 +0200 |
---|---|---|
committer | Daniel Bevenius <daniel.bevenius@gmail.com> | 2020-05-18 06:16:04 +0200 |
commit | b477ac83e6082fe0e76fb4c640cbfe7b864bbd02 (patch) | |
tree | f9107b2115328075226f7b5375193bc609e80f24 | |
parent | a12a2d892fadf8d8f6c5482056b937c9e1f89df4 (diff) | |
download | node-new-b477ac83e6082fe0e76fb4c640cbfe7b864bbd02.tar.gz |
src: add promise_resolve to SetupHooks comment
This commit adds promise_resolve to the list of callbacks mentioned in
the comment. It also fixes a minor typo, every -> ever.
PR-URL: https://github.com/nodejs/node/pull/33365
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Gerhard Stöbich <deb2001-github@yahoo.de>
Reviewed-By: James M Snell <jasnell@gmail.com>
-rw-r--r-- | src/async_wrap.cc | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/async_wrap.cc b/src/async_wrap.cc index 602b0e9f5d..f5a0def438 100644 --- a/src/async_wrap.cc +++ b/src/async_wrap.cc @@ -391,9 +391,10 @@ static void SetupHooks(const FunctionCallbackInfo<Value>& args) { CHECK(args[0]->IsObject()); - // All of init, before, after, destroy are supplied by async_hooks - // internally, so this should every only be called once. At which time all - // the functions should be set. Detect this by checking if init !IsEmpty(). + // All of init, before, after, destroy, and promise_resolve are supplied by + // async_hooks internally, so this should only ever be called once. At which + // time all the functions should be set. Detect this by checking if + // init !IsEmpty(). CHECK(env->async_hooks_init_function().IsEmpty()); Local<Object> fn_obj = args[0].As<Object>(); |