From 7d93c9930c908a0f827b8da830881ad34360367c Mon Sep 17 00:00:00 2001 From: coderaiser Date: Mon, 15 Sep 2014 10:45:54 -0400 Subject: [PATCH] feature(server) exports.start -> module.exports --- cloudcmd.js | 2 +- lib/server.js | 6 ++---- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/cloudcmd.js b/cloudcmd.js index e1c5d420..1e421763 100644 --- a/cloudcmd.js +++ b/cloudcmd.js @@ -61,7 +61,7 @@ writeLogsToFile(); } - server.start(); + server(); } function readConfig(callback) { diff --git a/lib/server.js b/lib/server.js index 7ae989cb..99e4a68b 100644 --- a/lib/server.js +++ b/lib/server.js @@ -56,7 +56,7 @@ * start server function * */ - function start() { + module.exports = function() { var port, ip, HTTP = 'http://', config = main.config; @@ -71,7 +71,7 @@ if (config.server) createServer(port, ip, HTTP); - } + }; function createServer(port, ip, protocol, callback) { var server, app, respondApp, @@ -201,6 +201,4 @@ return controller.bind(null, dir); }; - exports.start = start; - })();