summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMax Wu2016-09-06 20:36:40 +0800
committerGitHub2016-09-06 20:36:40 +0800
commit1d210d1fa53897c2741a1c6d55151a0df6215efc (patch)
tree66fbe7539b45c596442664245039b6ee62b0d379
parentc8f2ec4d3d25a6e872d0beee8b79e25b10ddcf36 (diff)
parent56a3a1d85da0f01d6ee53e1b7ca3a13de30476ab (diff)
Merge pull request #168 from zored/master
Removed redundant condition.
Diffstat (limited to '')
-rw-r--r--app.js16
1 files changed, 5 insertions, 11 deletions
diff --git a/app.js b/app.js
index 04172b80..e0e86fff 100644
--- a/app.js
+++ b/app.js
@@ -509,17 +509,11 @@ io.sockets.on('connection', realtime.connection);
//listen
function startListen() {
- if (config.usessl) {
- server.listen(config.port, function () {
- logger.info('HTTPS Server listening at port %d', config.port);
- config.maintenance = false;
- });
- } else {
- server.listen(config.port, function () {
- logger.info('HTTP Server listening at port %d', config.port);
- config.maintenance = false;
- });
- }
+ server.listen(config.port, function () {
+ var schema = config.usessl ? 'HTTPS' : 'HTTP';
+ logger.info('%s Server listening at port %d', schema, config.port);
+ config.maintenance = false;
+ });
}
// sync db then start listen