diff options
author | Minteck <minteck@phoenixnet.tech> | 2021-10-02 18:37:33 +0200 |
---|---|---|
committer | Minteck <minteck@phoenixnet.tech> | 2021-10-02 18:37:33 +0200 |
commit | a6b193d99f1dd88674291367df4d09cb117ef5d3 (patch) | |
tree | f48acef0aeac6352ed6f95950104ee92a87edf05 | |
parent | 4a210e42a235bfa190ab730c1043dd97becbc775 (diff) | |
download | kartik-iridium-a6b193d99f1dd88674291367df4d09cb117ef5d3.tar.gz kartik-iridium-a6b193d99f1dd88674291367df4d09cb117ef5d3.tar.bz2 kartik-iridium-a6b193d99f1dd88674291367df4d09cb117ef5d3.zip |
Fix the code that contains invalid characters
-rw-r--r-- | index.js | 4 | ||||
-rw-r--r-- | package.json | 2 |
2 files changed, 3 insertions, 3 deletions
@@ -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; diff --git a/package.json b/package.json index fa6d619..32fff14 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "iridium", - "version": "2.1.3", + "version": "2.2.0", "description": "A next-generation Kartik server, based on the original server", "main": "index.js", "scripts": { |