summaryrefslogtreecommitdiff
path: root/app.js
diff options
context:
space:
mode:
authorWu Cheng-Han2015-07-11 12:44:16 +0800
committerWu Cheng-Han2015-07-11 12:44:16 +0800
commit0292bfce5bb6f62363be8b54db064f642a899526 (patch)
tree914aa7ebe1262dffc9aaf1b4ec0ed56ec32550dc /app.js
parent556338a9c6964d110c1351a402b425c71c2571fa (diff)
Server using logger to log uncaughtException
Diffstat (limited to 'app.js')
-rw-r--r--app.js5
1 files changed, 4 insertions, 1 deletions
diff --git a/app.js b/app.js
index 8f84a021..628f4631 100644
--- a/app.js
+++ b/app.js
@@ -387,4 +387,7 @@ if (config.usessl) {
server.listen(config.port, function () {
logger.info('HTTP Server listening at port %d', config.port);
});
-} \ No newline at end of file
+}
+process.on('uncaughtException', function (err) {
+ logger.error(err);
+}); \ No newline at end of file