Skip to content

Commit 4873a23

Browse files
fix: restore the cherry-picking of the WebSocket options
The previous commit ([1]) makes the Engine.IO tests with Node.js SSL options fail. [1]: 177b95f
1 parent 8228a43 commit 4873a23

File tree

1 file changed

+15
-1
lines changed

1 file changed

+15
-1
lines changed

lib/transports/websocket.js

+15-1
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,21 @@ class WS extends Transport {
5454
const protocols = this.opts.protocols;
5555

5656
// React Native only supports the 'headers' option, and will print a warning if anything else is passed
57-
const opts = isReactNative ? {} : this.opts;
57+
const opts = isReactNative
58+
? {}
59+
: pick(
60+
this.opts,
61+
"agent",
62+
"perMessageDeflate",
63+
"pfx",
64+
"key",
65+
"passphrase",
66+
"cert",
67+
"ca",
68+
"ciphers",
69+
"rejectUnauthorized",
70+
"localAddress"
71+
);
5872

5973
if (this.opts.extraHeaders) {
6074
opts.headers = this.opts.extraHeaders;

0 commit comments

Comments
 (0)