Subject: Built motion from commit b983a9c.|0.0.141
From: Daniele Cinti <[email-masked]>
Date: Mon, 12 Sep 2016 09:18:08 +0000 (+0200)

Built motion from commit b983a9c.|0.0.141
---

diff --git a/server/app.js b/server/app.js
index 1aec51a..5ac497a 100644
--- a/server/app.js
+++ b/server/app.js
@@ -43,6 +43,18 @@ var sio_redis = require('socket.io-redis');
 var app = express();
 var server = http.createServer(app);
 
+var io = require('socket.io')(server, {
+  serveClient: (config.env === 'production') ? false : true,
+  path: '/socket.io-client'
+});
+
+io.adapter(redis({
+  host: config.ip,
+  port: 6379
+}));
+
+require('./config/socketio')(io, require('./services/dashboard')(io));
+
 if (!sticky.listen(server, config.port)) {
   // Master code
   server.once('listening', function() {
@@ -106,17 +118,7 @@ if (!sticky.listen(server, config.port)) {
 } else {
   // Slave code
 
-  var io = require('socket.io')(server, {
-    serveClient: (config.env === 'production') ? false : true,
-    path: '/socket.io-client'
-  });
-
-  io.adapter(redis({
-    host: config.ip,
-    port: 6379
-  }));
 
-  require('./config/socketio')(io, require('./services/dashboard')(io));
   require('./config/express')(app);
   require('./routes')(app, ami);
 }