From a7be98be0419653fb8efcc84601a2fcb0b88f166 Mon Sep 17 00:00:00 2001 From: Ylian Saint-Hilaire Date: Wed, 8 Apr 2020 11:02:51 -0700 Subject: [PATCH] Fixed server crash on some syslog setup. --- meshcentral.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meshcentral.js b/meshcentral.js index 4977ee21..d1301793 100644 --- a/meshcentral.js +++ b/meshcentral.js @@ -1495,7 +1495,7 @@ function CreateMeshCentralServer(config, args) { // Send event to syslog is needed if (obj.syslog && event.msg) { obj.syslog.log(obj.syslog.LOG_INFO, event.msg); } - if (obj.syslogjson) { obj.syslog.log(obj.syslogjson.LOG_INFO, JSON.stringify(event)); } + if (obj.syslogjson) { obj.syslogjson.log(obj.syslogjson.LOG_INFO, JSON.stringify(event)); } obj.debug('dispatch', 'DispatchEvent', ids); if ((typeof event == 'object') && (!event.nolog)) {