diff --git a/src/session/view/content/room_history/message_toolbar/mod.rs b/src/session/view/content/room_history/message_toolbar/mod.rs index a2b164b2..f4aafb5f 100644 --- a/src/session/view/content/room_history/message_toolbar/mod.rs +++ b/src/session/view/content/room_history/message_toolbar/mod.rs @@ -558,6 +558,11 @@ impl MessageToolbar { formatted_body.replace_range(.."/me ".len(), ""); } + if plain_body.trim().is_empty() { + // Don't send empty message. + return; + } + let html_body = if is_markdown { FormattedBody::markdown(formatted_body).map(|b| b.body) } else if has_mentions {