fix: missing defined type
authorxangelo <git@xangelo.ca>
Mon, 5 Jun 2023 18:54:07 +0000 (14:54 -0400)
committerxangelo <git@xangelo.ca>
Mon, 5 Jun 2023 18:54:07 +0000 (14:54 -0400)
src/server/api.ts
src/server/chat-commands/server-broadcast.ts [new file with mode: 0644]

index 99b470af0ce9a089277c88759257221b09283904..5f9693e23c5f20f8656fd2bc9f92a62943577b33 100644 (file)
@@ -102,7 +102,7 @@ io.on('connection', async socket => {
   socket.on('chat', (msg: string) => {
     if(msg.length > 0) {
 
-      let message;
+      let message: Message;
       if(msg.startsWith('/server lmnop')) {
         message = broadcastMessage('server', msg.split('/server lmnop ')[1]);
       }
diff --git a/src/server/chat-commands/server-broadcast.ts b/src/server/chat-commands/server-broadcast.ts
new file mode 100644 (file)
index 0000000..e69de29