async_hooks: use scope for defaultTriggerAsyncId
Previously the getter would mutate the kDefaultTriggerAsncId value. This refactor changes the setter to bind the current kDefaultTriggerAsncId to a scope, such that the getter doesn't have to mutate its own value. Backport-PR-URL: https://github.com/nodejs/node/pull/18179 PR-URL: https://github.com/nodejs/node/pull/17273 Reviewed-By:Matteo Collina <matteo.collina@gmail.com> Reviewed-By:
James M Snell <jasnell@gmail.com>
parent
03873db4
Please register or sign in to comment