From 02a53f681f1004ad5684b9957e19112b20785abf Mon Sep 17 00:00:00 2001 From: AJ ONeal Date: Wed, 5 Sep 2018 01:21:47 -0600 Subject: [PATCH] don't destroy empty socket --- bin/telebitd.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/telebitd.js b/bin/telebitd.js index 9901a26..7d838cd 100755 --- a/bin/telebitd.js +++ b/bin/telebitd.js @@ -849,7 +849,7 @@ function startTelebitRemote(rawCb) { }); function retryLoop() { // disconnected somehow - myRemote.destroy(); + if (myRemote) { myRemote.destroy(); } myRemote = null; setTimeout(function () { startTelebitRemote(function () {});