v1.18.x
Barış Soner Uşaklı 4 years ago
parent 70852c24de
commit a3d6c56ec3

@ -122,7 +122,7 @@
"socket.io": "4.1.1",
"socket.io-adapter-cluster": "^1.0.1",
"socket.io-client": "4.1.1",
"socket.io-redis": "6.1.0",
"@socket.io/redis-adapter": "7.0.0",
"sortablejs": "1.13.0",
"spdx-license-list": "^6.4.0",
"spider-detector": "2.0.0",

@ -104,13 +104,11 @@ redisModule.info = async function (cxn) {
};
redisModule.socketAdapter = async function () {
const redisAdapter = require('socket.io-redis');
const redisAdapter = require('@socket.io/redis-adapter');
const pub = await connection.connect(nconf.get('redis'));
const sub = await connection.connect(nconf.get('redis'));
return redisAdapter({
return redisAdapter(pub, sub, {
key: `db:${nconf.get('redis:database')}:adapter_key`,
pubClient: pub,
subClient: sub,
});
};

Loading…
Cancel
Save