Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nodejs/node.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnna Henningsen <anna@addaleax.net>2020-07-07 23:03:17 +0300
committerAnna Henningsen <anna@addaleax.net>2020-07-14 16:13:34 +0300
commita038199265519fa4db88a639b0e438675d23c4d1 (patch)
tree66b40d0be7e8c67e9d69593d6e00d8fd2b2ca319 /src/node_crypto.cc
parent2a29650eb328417de68beb617b22e83810e9296a (diff)
src,doc,test: remove String::New default parameter
`kNormal` has been the implicit default for a while now (since V8 7.6). Refs: https://github.com/v8/v8/commit/e0d7f816990ada28ebe1281ca9431236ef8c6e4f PR-URL: https://github.com/nodejs/node/pull/34248 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Tobias Nießen <tniessen@tnie.de> Reviewed-By: James M Snell <jasnell@gmail.com>
Diffstat (limited to 'src/node_crypto.cc')
-rw-r--r--src/node_crypto.cc7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/node_crypto.cc b/src/node_crypto.cc
index eae0f2e49d3..dfc21ae6876 100644
--- a/src/node_crypto.cc
+++ b/src/node_crypto.cc
@@ -392,8 +392,7 @@ void ThrowCryptoError(Environment* env,
}
HandleScope scope(env->isolate());
Local<String> exception_string =
- String::NewFromUtf8(env->isolate(), message, NewStringType::kNormal)
- .ToLocalChecked();
+ String::NewFromUtf8(env->isolate(), message).ToLocalChecked();
CryptoErrorVector errors;
errors.Capture();
Local<Value> exception;
@@ -1017,8 +1016,8 @@ void GetRootCertificates(const FunctionCallbackInfo<Value>& args) {
for (size_t i = 0; i < arraysize(root_certs); i++) {
if (!String::NewFromOneByte(
env->isolate(),
- reinterpret_cast<const uint8_t*>(root_certs[i]),
- NewStringType::kNormal).ToLocal(&result[i])) {
+ reinterpret_cast<const uint8_t*>(root_certs[i]))
+ .ToLocal(&result[i])) {
return;
}
}