aboutsummaryrefslogtreecommitdiff
path: root/index.js
diff options
context:
space:
mode:
Diffstat (limited to 'index.js')
-rw-r--r--index.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/index.js b/index.js
index c325a13..95623ff 100644
--- a/index.js
+++ b/index.js
@@ -54,9 +54,9 @@ class KartikError extends Error {
const server = new Net.Server();
server.on('connection', (socket) => {
- socket.connectionId = "ird-" + (Math.random().toString().split(".")[1] + Math.random().toString().split(".")[1]).substr(0, 4);
+ socket.connectionId = "irid" + (Math.random().toString().split(".")[1] + Math.random().toString().split(".")[1]).substr(0, 4);
while (Object.keys(clients).includes(socket.connectionId)) {
- socket.connectionId = "ird-" + (Math.random().toString().split(".")[1] + Math.random().toString().split(".")[1]).substr(0, 4);
+ socket.connectionId = "irid" + (Math.random().toString().split(".")[1] + Math.random().toString().split(".")[1]).substr(0, 4);
}
socket.linkedTo = null;
clients[socket.connectionId] = socket;