From b86f7cb9e0a4af41757e1aff15f7f905366fedb3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn=20Dahlgren?= Date: Sun, 23 Jan 2022 20:47:57 +0100 Subject: [PATCH] Convert server process error to string before writing to stream --- lib/logs.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/logs.js b/lib/logs.js index 3e30109..cc9b2f5 100644 --- a/lib/logs.js +++ b/lib/logs.js @@ -164,8 +164,8 @@ Logs.prototype.logServerProcess = function (serverProcess, prefix, suffix) { }) serverProcess.on('error', function (err) { - if (logStream) { - logStream.write(err) + if (logStream && err) { + logStream.write(err.toString()) } }) }