Skip to content

Commit

Permalink
Remove unnecessary console log and improve error handling in friends …
Browse files Browse the repository at this point in the history
…request handler
  • Loading branch information
tako0614 committed Jun 16, 2024
1 parent 60cacc5 commit dfdf60f
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions routes/api/v1/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -515,10 +515,12 @@ async function readMessage(messageids: [string], sender: string) {
(session) => session.uuid === sender,
)
if (!session) {
console.log("session is not found")
return
}
//messageidsが全てuuidか確認
if (messageids.some((messageid) => messageid.length !== 36)) {
console.log("messageids is not uuid")
return
}
session.ws.send(
Expand Down

0 comments on commit dfdf60f

Please sign in to comment.