Skip to content

Commit

Permalink
doc: clarify tls.Server 'connection' event documentation
Browse files Browse the repository at this point in the history
PR-URL: #41917
Fixes: #41880
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
  • Loading branch information
prettydiff authored and bengl committed Feb 22, 2022
1 parent 24b0a56 commit b0e8ccb
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions doc/api/tls.md
Original file line number Diff line number Diff line change
Expand Up @@ -480,8 +480,9 @@ added: v0.3.2
* `socket` {stream.Duplex}

This event is emitted when a new TCP stream is established, before the TLS
handshake begins. `socket` is typically an object of type [`net.Socket`][].
Usually users will not want to access this event.
handshake begins. `socket` is typically an object of type [`net.Socket`][] but
will not receive events unlike the socket created from the [`net.Server`][]
`'connection'` event. Usually users will not want to access this event.

This event can also be explicitly emitted by users to inject connections
into the TLS server. In that case, any [`Duplex`][] stream can be passed.
Expand Down

0 comments on commit b0e8ccb

Please sign in to comment.