src: fix Set() usage in node.h

PR-URL: https://github.com/nodejs/node/pull/24060
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
pull/24060/head
cjihrig 2018-11-03 11:41:17 -04:00
parent 5c9a4b23a8
commit ff0719d5fb
No known key found for this signature in database
GPG Key ID: 7434390BDBE9B9C5
1 changed files with 1 additions and 1 deletions

View File

@ -369,7 +369,7 @@ inline void NODE_SET_METHOD(v8::Local<v8::Object> recv,
v8::Local<v8::String> fn_name = v8::String::NewFromUtf8(isolate, name,
v8::NewStringType::kInternalized).ToLocalChecked();
fn->SetName(fn_name);
recv->Set(fn_name, fn);
recv->Set(context, fn_name, fn).FromJust();
}
#define NODE_SET_METHOD node::NODE_SET_METHOD