1
0
mirror of https://github.com/lensapp/lens.git synced 2025-05-20 05:10:56 +00:00

Check if this.socket is available

Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>
This commit is contained in:
Alex Andreev 2022-02-16 10:19:23 +03:00
parent d656a9e289
commit 8888550a88

View File

@ -181,7 +181,7 @@ export class WebSocketApi<Events extends WebSocketEvents> extends (EventEmitter
if (error) {
const { reconnectDelay } = this.params;
if (reconnectDelay) {
if (reconnectDelay && this.socket) {
const url = this.socket.url;
this.writeLog("will reconnect in", `${reconnectDelay}s`);