From f8e4a3fc34b72db7675ccb61fd028a185b50b5bc Mon Sep 17 00:00:00 2001 From: calzoneman Date: Thu, 14 Nov 2013 16:44:40 -0600 Subject: [PATCH] Fix exception handler exception --- lib/torblocker.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/torblocker.js b/lib/torblocker.js index 9fee4706..f7b324c4 100644 --- a/lib/torblocker.js +++ b/lib/torblocker.js @@ -24,7 +24,10 @@ function retrieveIPs(cb) { var d = domain.create(); d.on("error", function (err) { - Logger.errlog.log(err.trace()); + if (err.trace) + Logger.errlog.log(err.trace()); + else + Logger.errlog.log(err); }); d.run(function () {