diff options
Diffstat (limited to 'libdino/src')
-rw-r--r-- | libdino/src/service/message_manager.vala | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/libdino/src/service/message_manager.vala b/libdino/src/service/message_manager.vala index 9f87c932..d159158b 100644 --- a/libdino/src/service/message_manager.vala +++ b/libdino/src/service/message_manager.vala @@ -85,8 +85,10 @@ public class MessageManager : StreamInteractionModule, Object { private void send_unsent_messages(Account account) { Gee.List<Entities.Message> unsend_messages = db.get_unsend_messages(account); foreach (Entities.Message message in unsend_messages) { - Conversation conversation = ConversationManager.get_instance(stream_interactor).get_conversation(message.counterpart, account); - send_xmpp_message(message, conversation, true); + Conversation? conversation = ConversationManager.get_instance(stream_interactor).get_conversation(message.counterpart, account); + if (conversation != null) { + send_xmpp_message(message, conversation, true); + } } } |