From 6b6b0c74ddd6f4717d289b597d0c4504c66c4cf7 Mon Sep 17 00:00:00 2001 From: Mohamad Date: Sat, 14 Dec 2024 00:45:02 +0330 Subject: [PATCH] Fix type --- server/src/ws/protocol.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/server/src/ws/protocol.ts b/server/src/ws/protocol.ts index 790ae99e..096b0dd1 100644 --- a/server/src/ws/protocol.ts +++ b/server/src/ws/protocol.ts @@ -4,6 +4,7 @@ import { t, type Static } from "elysia" import { Input as GetMeInput } from "@in/server/methods/getMe" import { nanoid } from "nanoid/non-secure" import { TUpdate } from "@in/server/models" +import type { StaticDecode, StaticEncode } from "@sinclair/typebox" const Methods = t.Union([ t.Object({ @@ -97,7 +98,7 @@ export const ServerMessage = t.Union([ }), ]) -export type ServerMessageType = Static +export type ServerMessageType = StaticDecode export const enum ClientMessageKind { ConnectionInit = 1, // used for connection initialization with auth