@@ -40,7 +40,7 @@ there to be one or more C++ wrapper modules that provide an inlineable C++
4040API. Binaries built with these wrapper modules will depend on the symbols
4141for the N-API C based functions exported by Node.js. These wrappers are not
4242part of N-API, nor will they be maintained as part of Node.js. One such
43- example is: [node-api](https://github.com/nodejs/node-api).
43+ example is: [node-addon- api](https://github.com/nodejs/node-addon -api).
4444
4545In order to use the N-API functions, include the file
4646[`node_api.h`](https://github.com/nodejs/node/blob/master/src/node_api.h)
@@ -73,7 +73,9 @@ typedef enum {
7373 napi_generic_failure,
7474 napi_pending_exception,
7575 napi_cancelled,
76- napi_status_last
76+ napi_escape_called_twice,
77+ napi_handle_scope_mismatch,
78+ napi_callback_scope_mismatch
7779} napi_status;
7880```
7981If additional information is required upon an API returning a failed status,
@@ -589,7 +591,7 @@ that has a loop which iterates through the elements in a large array:
589591```C
590592for (int i = 0; i < 1000000; i++) {
591593 napi_value result;
592- napi_status status = napi_get_element(e , object, i, &result);
594+ napi_status status = napi_get_element(env , object, i, &result);
593595 if (status != napi_ok) {
594596 break;
595597 }
@@ -626,7 +628,7 @@ for (int i = 0; i < 1000000; i++) {
626628 break;
627629 }
628630 napi_value result;
629- status = napi_get_element(e , object, i, &result);
631+ status = napi_get_element(env , object, i, &result);
630632 if (status != napi_ok) {
631633 break;
632634 }
@@ -2486,10 +2488,10 @@ performed using a N-API call).
24862488property to be a JavaScript function represented by `method`. If this is
24872489passed in, set `value`, `getter` and `setter` to `NULL` (since these members
24882490won't be used).
2489- - `data`: The callback data passed into `method`, `getter` and `setter` if
2490- this function is invoked.
24912491- `attributes`: The attributes associated with the particular property.
24922492See [`napi_property_attributes`](#n_api_napi_property_attributes).
2493+ - `data`: The callback data passed into `method`, `getter` and `setter` if
2494+ this function is invoked.
24932495
24942496### Functions
24952497#### napi_get_property_names
0 commit comments