From e00e92fc733bc569a90c399e01b277df1aac5c37 Mon Sep 17 00:00:00 2001 From: March 7th <71698422+aiko-chan-ai@users.noreply.github.com> Date: Wed, 4 Jan 2023 12:13:24 +0700 Subject: [PATCH] Update WebSocketShard.js --- src/client/websocket/WebSocketShard.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/client/websocket/WebSocketShard.js b/src/client/websocket/WebSocketShard.js index fe6622a..b6974a2 100644 --- a/src/client/websocket/WebSocketShard.js +++ b/src/client/websocket/WebSocketShard.js @@ -262,7 +262,7 @@ class WebSocketShard extends EventEmitter { Version : ${client.options.ws.version} Encoding : ${WebSocket.encoding} Compression: ${zlib ? 'zlib-stream' : 'none'} - Proxy : ${client.options.ws.proxy || 'none'}`, + Proxy : ${client.options.proxy || 'none'}`, ); this.status = this.status === Status.DISCONNECTED ? Status.RECONNECTING : Status.CONNECTING; @@ -271,7 +271,7 @@ class WebSocketShard extends EventEmitter { this.connectedAt = Date.now(); let args = { handshakeTimeout: 30_000 }; - if (typeof client.options.proxy && client.options.proxy.length > 0) { + if (client.options.proxy.length > 0) { args.agent = new proxy(client.options.proxy); this.debug(`Using proxy ${client.options.proxy}`, args); }