From 7afe43741f527345bbd073d79c0fecd9d9fe4761 Mon Sep 17 00:00:00 2001 From: Terje Andre Johansen Date: Wed, 12 Jun 2024 21:04:29 +0200 Subject: [PATCH] Added a generic to Room.ts send method --- src/Room.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Room.ts b/src/Room.ts index 2e49f92..7be05f7 100644 --- a/src/Room.ts +++ b/src/Room.ts @@ -128,7 +128,7 @@ export class Room { return this.onMessageHandlers.on(this.getMessageHandlerKey(type), callback); } - public send(type: string | number, message?: any): void { + public send(type: string | number, message?: T): void { const initialBytes: number[] = [Protocol.ROOM_DATA]; if (typeof(type) === "string") {