fix agentidletimeout being undefined

Signed-off-by: si458 <simonsmith5521@gmail.com>

si458 committed Aug 5, 2024 at 11:48 UTC 6f2b57998f3903a27758f71fb0f2869aa34e8607
1 file changed +1 -1
meshcentral.js
+1 -1
@@ -1519,7 +1519,7 @@ function CreateMeshCentralServer(config, args) {
1519 if (obj.args.rediraliasport != null && (typeof obj.args.rediraliasport != 'number')) obj.args.rediraliasport = null;
1520 if (obj.args.redirport == null) obj.args.redirport = 80;
1521 if (obj.args.minifycore == null) obj.args.minifycore = false;
1522 - if (typeof args.agentidletimeout != 'number') { args.agentidletimeout = 150000; } else { args.agentidletimeout *= 1000 } // Default agent idle timeout is 2m, 30sec.
1522 + if (typeof obj.args.agentidletimeout != 'number') { obj.args.agentidletimeout = 150000; } else { obj.args.agentidletimeout *= 1000 } // Default agent idle timeout is 2m, 30sec.
1523 if ((obj.args.lanonly != true) && (obj.args.webrtconfig == null)) { obj.args.webrtconfig = { iceservers: [{ urls: 'stun:stun.l.google.com:19302' }, { urls: 'stun:stun.services.mozilla.com' }] }; } // Setup default WebRTC STUN servers
1524 if (typeof obj.args.ignoreagenthashcheck == 'string') { if (obj.args.ignoreagenthashcheck == '') { delete obj.args.ignoreagenthashcheck; } else { obj.args.ignoreagenthashcheck = obj.args.ignoreagenthashcheck.split(','); } }
1525