aboutsummaryrefslogtreecommitdiffstats
path: root/server/src/commands/core
diff options
context:
space:
mode:
Diffstat (limited to 'server/src/commands/core')
-rw-r--r--server/src/commands/core/chat.js1
-rw-r--r--server/src/commands/core/disconnect.js21
-rw-r--r--server/src/commands/core/ping.js12
3 files changed, 13 insertions, 21 deletions
diff --git a/server/src/commands/core/chat.js b/server/src/commands/core/chat.js
index 80241d5..168c0bb 100644
--- a/server/src/commands/core/chat.js
+++ b/server/src/commands/core/chat.js
@@ -48,6 +48,7 @@ exports.run = async (core, server, socket, data) => {
payload.trip = socket.trip;
}
+ // TODO: Add a more contained way for modules to interact, event hooks or something?
if(core.muzzledHashes && core.muzzledHashes[socket.hash]){
server.broadcast( payload, { channel: socket.channel, hash: socket.hash });
if(core.muzzledHashes[socket.hash].allies){
diff --git a/server/src/commands/core/disconnect.js b/server/src/commands/core/disconnect.js
deleted file mode 100644
index 9b54214..0000000
--- a/server/src/commands/core/disconnect.js
+++ /dev/null
@@ -1,21 +0,0 @@
-/*
- Description: This module will be directly called by the server event handler
- when a socket connection is closed or lost. It can calso be called
- by a client to have the connection severed.
-*/
-
-exports.run = async (core, server, socket, data) => {
- if (socket.channel) {
- server.broadcast({
- cmd: 'onlineRemove',
- nick: socket.nick
- }, { channel: socket.channel });
- }
-
- socket.terminate();
-};
-
-exports.info = {
- name: 'disconnect',
- description: 'Event handler or force disconnect (if your into that kind of thing)'
-}; \ No newline at end of file
diff --git a/server/src/commands/core/ping.js b/server/src/commands/core/ping.js
new file mode 100644
index 0000000..cf1d8a4
--- /dev/null
+++ b/server/src/commands/core/ping.js
@@ -0,0 +1,12 @@
+/*
+ Description: This module is only in place to supress error notices legacy sources may get
+*/
+
+exports.run = async (core, server, socket, data) => {
+ return;
+};
+
+exports.info = {
+ name: 'ping',
+ description: 'This module is only in place to supress error notices legacy sources may get'
+};