Skip to content

Commit

Permalink
Listen on same port as webserver.
Browse files Browse the repository at this point in the history
  • Loading branch information
Gabriel Cardona committed Jul 22, 2018
1 parent b0e73c8 commit c604005
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ let apiSpec = require('./public/bitbox-rest-v1.json');
require('dotenv').config()

let app = express();
let io = require('socket.io').listen(app.listen(3001));

let index = require('./routes/index');
let healthCheck = require('./routes/health-check');
Expand Down Expand Up @@ -133,6 +132,7 @@ app.set('port', port);
*/

let server = http.createServer(app);
let io = require('socket.io').listen(server);

io.on('connection', (socket) => {

Expand Down

0 comments on commit c604005

Please sign in to comment.