aboutsummaryrefslogtreecommitdiffstats
path: root/lib/sockets.js
diff options
context:
space:
mode:
Diffstat (limited to 'lib/sockets.js')
-rw-r--r--lib/sockets.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/sockets.js b/lib/sockets.js
index 87cf7116..fb007a17 100644
--- a/lib/sockets.js
+++ b/lib/sockets.js
@@ -85,7 +85,7 @@ app.register(async function(app) {
switch (type) {
case "heartbeat":
ws.beats = 0;
- if (ws.user) emit(ws.user.username, "id", ws.id);
+ ws.send(JSON.stringify({ type: "id", data: ws.id }));
break;
case "login":