mirror of
https://github.com/litruv/DAdmin.git
synced 2026-07-26 03:36:13 +10:00
more wss stabilizations
This commit is contained in:
@@ -44,7 +44,12 @@ module.exports = {
|
|||||||
});
|
});
|
||||||
|
|
||||||
dclient.on('message', (message) => {
|
dclient.on('message', (message) => {
|
||||||
ws.send(stringify(message))
|
wss.clients.forEach(function each(client) {
|
||||||
|
if (client !== ws && client.readyState === WebSocket.OPEN) {
|
||||||
|
client.send(stringify(message))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
})
|
})
|
||||||
// ws.send('something');
|
// ws.send('something');
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user