Commit 02f3dd24 authored by Chetan Karande's avatar Chetan Karande Committed by Rich Trott
Browse files

doc: fix unsafe writable stream code example

Update writable stream code example using async iterator to use safer
`finished()` method instead of a `finish` event to avoid uncaught
exceptions

Fixes: https://github.com/nodejs/node/issues/29397

PR-URL: https://github.com/nodejs/node/pull/29425


Reviewed-By: default avatarJames M Snell <jasnell@gmail.com>
Reviewed-By: default avatarLuigi Pinca <luigipinca@gmail.com>
Reviewed-By: default avatarTrivikram Kamat <trivikr.dev@gmail.com>
parent 9c57e4de
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment