Skip to content

Commit b8a7f63

Browse files
RafaelGSSdanielleadams
authored andcommitted
doc: add usage recommendation for writable._destroy
PR-URL: #41040 Reviewed-By: Matteo Collina <[email protected]>
1 parent 263ddc0 commit b8a7f63

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

doc/api/stream.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2651,6 +2651,8 @@ added: v8.0.0
26512651

26522652
The `_destroy()` method is called by [`writable.destroy()`][writable-destroy].
26532653
It can be overridden by child classes but it **must not** be called directly.
2654+
Furthermore, the `callback` should not be mixed with async/await
2655+
once it is executed when a promise is resolved.
26542656

26552657
#### `writable._final(callback)`
26562658

0 commit comments

Comments
 (0)