mirror of
https://github.com/zebrajr/node.git
synced 2026-01-15 12:15:26 +00:00
src: use using NewStringType
PR-URL: https://github.com/nodejs/node/pull/32843 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Richard Lau <riclau@uk.ibm.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com> Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com>
This commit is contained in:
@@ -193,7 +193,7 @@ static void GetInterfaceAddresses(const FunctionCallbackInfo<Value>& args) {
|
||||
// they name the interface from any input that uses UTF-8, which should be
|
||||
// the most frequent case by far these days.)
|
||||
name = String::NewFromUtf8(isolate, raw_name,
|
||||
v8::NewStringType::kNormal).ToLocalChecked();
|
||||
NewStringType::kNormal).ToLocalChecked();
|
||||
|
||||
snprintf(mac.data(),
|
||||
mac.size(),
|
||||
@@ -253,7 +253,7 @@ static void GetHomeDirectory(const FunctionCallbackInfo<Value>& args) {
|
||||
|
||||
Local<String> home = String::NewFromUtf8(env->isolate(),
|
||||
buf,
|
||||
v8::NewStringType::kNormal,
|
||||
NewStringType::kNormal,
|
||||
len).ToLocalChecked();
|
||||
args.GetReturnValue().Set(home);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user