@@ -633,7 +633,7 @@ All [`Http2Stream`][] instances are destroyed either when:
633633When an ` Http2Stream ` instance is destroyed, an attempt will be made to send an
634634` RST_STREAM ` frame will be sent to the connected peer.
635635
636- Once the ` Http2Stream ` instance is destroyed, the ` 'streamClosed ' ` event will
636+ When the ` Http2Stream ` instance is destroyed, the ` 'close ' ` event will
637637be emitted. Because ` Http2Stream ` is an instance of ` stream.Duplex ` , the
638638` 'end' ` event will also be emitted if the stream data is currently flowing.
639639The ` 'error' ` event may also be emitted if ` http2stream.destroy() ` was called
@@ -655,6 +655,18 @@ abnormally aborted in mid-communication.
655655* Note* : The ` 'aborted' ` event will only be emitted if the ` Http2Stream `
656656writable side has not been ended.
657657
658+ #### Event: 'close'
659+ <!-- YAML
660+ added: v8.4.0
661+ -->
662+
663+ The ` 'close' ` event is emitted when the ` Http2Stream ` is destroyed. Once
664+ this event is emitted, the ` Http2Stream ` instance is no longer usable.
665+
666+ The listener callback is passed a single argument specifying the HTTP/2 error
667+ code specified when closing the stream. If the code is any value other than
668+ ` NGHTTP2_NO_ERROR ` (` 0 ` ), an ` 'error' ` event will also be emitted.
669+
658670#### Event: 'error'
659671<!-- YAML
660672added: v8.4.0
@@ -674,18 +686,6 @@ argument identifying the frame type, and an integer argument identifying the
674686error code. The ` Http2Stream ` instance will be destroyed immediately after the
675687` 'frameError' ` event is emitted.
676688
677- #### Event: 'streamClosed'
678- <!-- YAML
679- added: v8.4.0
680- -->
681-
682- The ` 'streamClosed' ` event is emitted when the ` Http2Stream ` is destroyed. Once
683- this event is emitted, the ` Http2Stream ` instance is no longer usable.
684-
685- The listener callback is passed a single argument specifying the HTTP/2 error
686- code specified when closing the stream. If the code is any value other than
687- ` NGHTTP2_NO_ERROR ` (` 0 ` ), an ` 'error' ` event will also be emitted.
688-
689689#### Event: 'timeout'
690690<!-- YAML
691691added: v8.4.0
0 commit comments