refactor: explicitly import socketio
This commit is contained in:
parent
5e4e60b509
commit
164840c32e
1 changed files with 2 additions and 1 deletions
|
|
@ -1,12 +1,13 @@
|
|||
const cookie = require("cookie");
|
||||
const request = require("superagent");
|
||||
const { Server } = require("socket.io");
|
||||
|
||||
const { get_conf, get_redis_subscriber } = require("../node_utils");
|
||||
const conf = get_conf();
|
||||
const log = console.log; // eslint-disable-line
|
||||
const subscriber = get_redis_subscriber();
|
||||
|
||||
const io = require("socket.io")(conf.socketio_port, {
|
||||
const io = new Server(conf.socketio_port, {
|
||||
cors: {
|
||||
// Should be fine since we are ensuring whether hostname and origin are same before adding setting listeners for s socket
|
||||
origin: true,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue