Skip to content

Commit d590ace

Browse files
committed
Fix typing indicator broadcast to exclude the sender by comparing client IDs
1 parent 9ce5f60 commit d590ace

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

internal/ws/ws.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ func (h *Hub) BroadcastTypingToConversation(conversationUUID string, typingMsg m
142142

143143
for _, client := range h.conversationClients[conversationUUID] {
144144
// Don't send typing indicator back to the sender.
145-
if client != sender {
145+
if client.ID != sender.ID {
146146
client.SendMessage(messageBytes, websocket.TextMessage)
147147
}
148148
}

0 commit comments

Comments
 (0)