From 594a84d8f2cb3c630744487d02dbcff05675d6cf Mon Sep 17 00:00:00 2001 From: Michaƫl Zasso Date: Sun, 2 Sep 2018 17:49:11 +0200 Subject: src: remove calls to deprecated V8 functions (Int32Value) Remove all calls to deprecated V8 functions (here: Value::Int32Value) inside the code. PR-URL: https://github.com/nodejs/node/pull/22662 Reviewed-By: Anna Henningsen Reviewed-By: Minwoo Jung Reviewed-By: James M Snell Reviewed-By: Ujjwal Sharma --- src/js_stream.cc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src/js_stream.cc') diff --git a/src/js_stream.cc b/src/js_stream.cc index 902aff7abe..4769a9c56d 100644 --- a/src/js_stream.cc +++ b/src/js_stream.cc @@ -14,6 +14,7 @@ using v8::Context; using v8::FunctionCallbackInfo; using v8::FunctionTemplate; using v8::HandleScope; +using v8::Int32; using v8::Local; using v8::Object; using v8::String; @@ -154,7 +155,8 @@ void JSStream::Finish(const FunctionCallbackInfo& args) { CHECK(args[0]->IsObject()); Wrap* w = static_cast(StreamReq::FromObject(args[0].As())); - w->Done(args[1]->Int32Value()); + CHECK(args[1]->IsInt32()); + w->Done(args[1].As()->Value()); } -- cgit v1.2.3