diff options
author | Anna Henningsen <anna@addaleax.net> | 2017-12-16 22:39:27 +0300 |
---|---|---|
committer | Anna Henningsen <anna@addaleax.net> | 2017-12-21 22:56:13 +0300 |
commit | 901e9a1983e30cd3913378b80be85f703be5fbc6 (patch) | |
tree | 7e2a65447f478a9fb1ab52a173298bcb3a79d02d /src/js_stream.cc | |
parent | 1af82f3d0e13a175c424017565189fffb2f49e83 (diff) |
src: remove redundant `JSStream::DoAfterWrite`
`Finish<WriteWrap>` already does the same thing and is
called immediately afterwards anyway.
PR-URL: https://github.com/nodejs/node/pull/17713
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Diffstat (limited to 'src/js_stream.cc')
-rw-r--r-- | src/js_stream.cc | 12 |
1 files changed, 0 insertions, 12 deletions
diff --git a/src/js_stream.cc b/src/js_stream.cc index 739d59df133..c4e32feeba0 100644 --- a/src/js_stream.cc +++ b/src/js_stream.cc @@ -169,17 +169,6 @@ void JSStream::New(const FunctionCallbackInfo<Value>& args) { } -void JSStream::DoAfterWrite(const FunctionCallbackInfo<Value>& args) { - JSStream* wrap; - CHECK(args[0]->IsObject()); - WriteWrap* w; - ASSIGN_OR_RETURN_UNWRAP(&wrap, args.Holder()); - ASSIGN_OR_RETURN_UNWRAP(&w, args[0].As<Object>()); - - w->Done(0); -} - - template <class Wrap> void JSStream::Finish(const FunctionCallbackInfo<Value>& args) { Wrap* w; @@ -234,7 +223,6 @@ void JSStream::Initialize(Local<Object> target, AsyncWrap::AddWrapMethods(env, t); - env->SetProtoMethod(t, "doAfterWrite", DoAfterWrite); env->SetProtoMethod(t, "finishWrite", Finish<WriteWrap>); env->SetProtoMethod(t, "finishShutdown", Finish<ShutdownWrap>); env->SetProtoMethod(t, "readBuffer", ReadBuffer); |