diff options
author | James M Snell <jasnell@gmail.com> | 2020-07-08 18:53:25 +0300 |
---|---|---|
committer | James M Snell <jasnell@gmail.com> | 2020-07-09 17:15:43 +0300 |
commit | fe11f6bf7cf8de128c224d06cb076e7fe571dfd3 (patch) | |
tree | b1dc5b5e842ee8f1152a987a566dcdf2497abbc8 /doc/api/quic.md | |
parent | d08e99de242898c40e9410b9cb1e86c1bb8f830f (diff) |
quic: cleanup QuicSocketFlags, used shared state struct
Some of the flags were no longer being used.
Switched to use an AliasedStruct for shared state to avoid
extraneous expensive JS=>C++ calls.
Removed unused QuicSocket option
PR-URL: https://github.com/nodejs/node/pull/34247
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Diffstat (limited to 'doc/api/quic.md')
-rw-r--r-- | doc/api/quic.md | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/doc/api/quic.md b/doc/api/quic.md index 1e71654badf..6143d3995cf 100644 --- a/doc/api/quic.md +++ b/doc/api/quic.md @@ -1327,17 +1327,17 @@ added: REPLACEME --> Emitted when the server busy state has been toggled using -`quicSocket.serverBusy = true | false`. The callback is invoked with a -single boolean argument indicating `true` if busy status is enabled, -`false` otherwise. This event is strictly informational. +`quicSocket.serverBusy = true | false`. The callback is invoked with no +arguments. Use the `quicsocket.serverBusy` property to determine the +current status. This event is strictly informational. ```js const { createQuicSocket } = require('net'); const socket = createQuicSocket(); -socket.on('busy', (busy) => { - if (busy) +socket.on('busy', () => { + if (socket.serverBusy) console.log('Server is busy'); else console.log('Server is not busy'); |