| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 25443fa commit cf88ed8
1 file changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -4672,8 +4672,13 @@ napi_status napi_async_init(napi_env env, | |||
| 4672 | 4672 | ``` | |
| 4673 | 4673 | ||
| 4674 | 4674 | * `[in] env`: The environment that the API is invoked under. | |
| 4675 | - * `[in] async_resource`: An optional object associated with the async work | ||
| 4675 | + * `[in] async_resource`: Object associated with the async work | ||
| 4676 | 4676 | that will be passed to possible `async_hooks` [`init` hooks][]. | |
| 4677 | + In order to retain ABI compatibility with previous versions, | ||
| 4678 | + passing `NULL` for `async_resource` will not result in an error, however, | ||
| 4679 | + this will result incorrect operation of async hooks for the | ||
| 4680 | + napi_async_context created. Potential issues include | ||
| 4681 | + loss of async context when using the AsyncLocalStorage API. | ||
| 4677 | 4682 | * `[in] async_resource_name`: Identifier for the kind of resource | |
| 4678 | 4683 | that is being provided for diagnostic information exposed by the | |
| 4679 | 4684 | `async_hooks` API. | |
| Back | FazBrowse Home | New Git URL |
0 commit comments