From 29563abd858aaeaae156ea6af81f511ac7ba1b41 Mon Sep 17 00:00:00 2001 From: Rafael Gonzaga Date: Wed, 22 Dec 2021 13:51:16 -0300 Subject: [PATCH] doc: add usage recommendation for writable._destroy PR-URL: https://github.com/nodejs/node/pull/41040 Reviewed-By: Matteo Collina --- doc/api/stream.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/doc/api/stream.md b/doc/api/stream.md index 5f898cc325bb7d..c52e5ff7617768 100644 --- a/doc/api/stream.md +++ b/doc/api/stream.md @@ -2689,6 +2689,8 @@ added: v8.0.0 The `_destroy()` method is called by [`writable.destroy()`][writable-destroy]. It can be overridden by child classes but it **must not** be called directly. +Furthermore, the `callback` should not be mixed with async/await +once it is executed when a promise is resolved. #### `writable._final(callback)`