From 233d12d8b1916eae5bae230dc965045adb89a173 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Sat, 19 Mar 2016 09:08:10 +0100 Subject: [PATCH] Fix exception log of the webtorrent process --- server/lib/webtorrent.js | 2 +- server/lib/webtorrentProcess.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/server/lib/webtorrent.js b/server/lib/webtorrent.js index 455b086a3..e2e2586f9 100644 --- a/server/lib/webtorrent.js +++ b/server/lib/webtorrent.js @@ -53,7 +53,7 @@ function create (options, callback) { }) ipc.server.on(processKey + '.exception', function (data) { - throw new Error('Received exception error from webtorrent process.' + data.exception) + throw new Error('Received exception error from webtorrent process : ' + data.exception) }) const webtorrent_process = spawn(pathUtils.join(__dirname, 'webtorrentProcess.js'), host, port, { detached: true }) diff --git a/server/lib/webtorrentProcess.js b/server/lib/webtorrentProcess.js index c68e97ee4..7889e7128 100644 --- a/server/lib/webtorrentProcess.js +++ b/server/lib/webtorrentProcess.js @@ -83,7 +83,7 @@ function webtorrent (args) { }) process.on('uncaughtException', function (e) { - ipc.of[nodeKey].emit(processKey + '.exception', { exception: e }) + ipc.of[nodeKey].emit(processKey + '.exception', { exception: e.toString() }) }) } -- 2.25.1