From 1dc06f7ad372649a9c33c5e2e13f2c90a0413479 Mon Sep 17 00:00:00 2001 From: syuilo Date: Sat, 19 Feb 2022 14:30:42 +0900 Subject: [PATCH] refactor: fix type --- packages/backend/src/server/api/stream/index.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/backend/src/server/api/stream/index.ts b/packages/backend/src/server/api/stream/index.ts index 84689bca1a..e0bb8033a2 100644 --- a/packages/backend/src/server/api/stream/index.ts +++ b/packages/backend/src/server/api/stream/index.ts @@ -109,7 +109,8 @@ export default class Connection { * クライアントからメッセージ受信時 */ @autobind - private async onWsConnectionMessage(data: websocket.IMessage) { + private async onWsConnectionMessage(data: websocket.Message) { + if (data.type !== 'utf8') return; if (data.utf8Data == null) return; let obj: Record;