Summary
GroupChatModule.sendMessage in the SDK never throws on publish failure — it catches and returns null (verified in the installed SDK: logger.error("GroupChat", "Failed to send message", error); return null). The mutation wraps it as return !!message, so it resolves with false instead of rejecting; onSuccess runs unconditionally and clears the input (setMessageInput('')), and the global mutation onError toast never fires. The user's typed group message is gone with zero feedback.
Where
src/components/chat/hooks/useGroupChat.ts:367.
Fix (app-side, immediate)
In mutationFn: if (!message) throw new Error('Failed to send message') so the global onError toast fires and onSuccess (input clearing) is skipped. Apply the same guard to the mini-chat/DM send flows and to deleteMessage/kickUser/createGroup (all fail silently today).
Companion SDK improvement (optional)
The proper upstream fix is for GroupChatModule.sendMessage (and the moderation methods) to surface failures — throw, or return a typed { ok: false, error } — instead of swallowing them and returning null. Tracked separately in the SDK repo.
Found by multi-agent audit @ main b477d4d; adversarially verified.
Summary
GroupChatModule.sendMessagein the SDK never throws on publish failure — it catches and returnsnull(verified in the installed SDK:logger.error("GroupChat", "Failed to send message", error); return null). The mutation wraps it asreturn !!message, so it resolves withfalseinstead of rejecting;onSuccessruns unconditionally and clears the input (setMessageInput('')), and the global mutationonErrortoast never fires. The user's typed group message is gone with zero feedback.Where
src/components/chat/hooks/useGroupChat.ts:367.Fix (app-side, immediate)
In
mutationFn:if (!message) throw new Error('Failed to send message')so the globalonErrortoast fires andonSuccess(input clearing) is skipped. Apply the same guard to the mini-chat/DM send flows and todeleteMessage/kickUser/createGroup(all fail silently today).Companion SDK improvement (optional)
The proper upstream fix is for
GroupChatModule.sendMessage(and the moderation methods) to surface failures — throw, or return a typed{ ok: false, error }— instead of swallowing them and returningnull. Tracked separately in the SDK repo.Found by multi-agent audit @ main b477d4d; adversarially verified.