diff options
author | Rich Trott <rtrott@gmail.com> | 2020-09-01 08:10:02 +0300 |
---|---|---|
committer | Rich Trott <rtrott@gmail.com> | 2020-09-03 15:25:06 +0300 |
commit | 449f73e05fdb17b76a11f6e122cadf80fdbdf9ba (patch) | |
tree | a7c6ed37c39b7284261edead889fa0490a0128fb /lib/internal/quic | |
parent | 79ea22a531c8446710b43df5f6eeb0497719f302 (diff) |
quic: remove undefined variable
The `reason` variable never gets defined. It's use in a template string
will always end up as the string `'undefined'`.
PR-URL: https://github.com/nodejs/node/pull/35007
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Diffstat (limited to 'lib/internal/quic')
-rw-r--r-- | lib/internal/quic/core.js | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/internal/quic/core.js b/lib/internal/quic/core.js index edb1113a2c2..2df63c2be67 100644 --- a/lib/internal/quic/core.js +++ b/lib/internal/quic/core.js @@ -2389,7 +2389,6 @@ class QuicClientSession extends QuicSession { // If handle is a number, creating the session failed. if (typeof handle === 'number') { - let reason; switch (handle) { case ERR_FAILED_TO_CREATE_SESSION: throw new ERR_QUIC_FAILED_TO_CREATE_SESSION(); @@ -2398,7 +2397,7 @@ class QuicClientSession extends QuicSession { case ERR_INVALID_TLS_SESSION_TICKET: throw new ERR_QUIC_INVALID_TLS_SESSION_TICKET(); default: - throw new ERR_OPERATION_FAILED(`Unspecified reason [${reason}]`); + throw new ERR_OPERATION_FAILED(`Unspecified reason [${handle}]`); } } |