From 65ba9fc39e8545785b08d949072405ab1c7a567a Mon Sep 17 00:00:00 2001 From: kumavis Date: Wed, 11 Jan 2017 19:09:49 -0800 Subject: [PATCH] bugfix - portstream - dont wrap cb in try catch --- app/scripts/lib/port-stream.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/scripts/lib/port-stream.js b/app/scripts/lib/port-stream.js index 6f4ccc6ab..607a9c9ed 100644 --- a/app/scripts/lib/port-stream.js +++ b/app/scripts/lib/port-stream.js @@ -51,11 +51,11 @@ PortDuplexStream.prototype._write = function (msg, encoding, cb) { // console.log('PortDuplexStream - sent message', msg) this._port.postMessage(msg) } - cb() } catch (err) { // console.error(err) - cb(new Error('PortDuplexStream - disconnected')) + return cb(new Error('PortDuplexStream - disconnected')) } + cb() } // util