mirror of
https://github.com/nodejs/node.git
synced 2026-11-25 23:01:06 -05:00
doc: hello addon example should return "world"
The N-API version of the hello example, returned "hello" instead of "world". PR-URL: https://github.com/nodejs/node/pull/26328 Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
This commit is contained in:
1 parent
99c555a1de
commit
a562aba84c
1 file changed
+1
-1
+1
-1
@@ -386,7 +386,7 @@ napi_value Method(napi_env env, napi_callback_info args) {
|
||||
napi_value greeting;
|
||||
napi_status status;
|
||||
|
||||
status = napi_create_string_utf8(env, "hello", NAPI_AUTO_LENGTH, &greeting);
|
||||
status = napi_create_string_utf8(env, "world", NAPI_AUTO_LENGTH, &greeting);
|
||||
if (status != napi_ok) return nullptr;
|
||||
return greeting;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user