aboutsummaryrefslogtreecommitdiff
path: root/libdino/src/service/message_processor.vala
diff options
context:
space:
mode:
Diffstat (limited to 'libdino/src/service/message_processor.vala')
-rw-r--r--libdino/src/service/message_processor.vala4
1 files changed, 3 insertions, 1 deletions
diff --git a/libdino/src/service/message_processor.vala b/libdino/src/service/message_processor.vala
index 6a66f343..74192e16 100644
--- a/libdino/src/service/message_processor.vala
+++ b/libdino/src/service/message_processor.vala
@@ -333,7 +333,9 @@ public class MessageProcessor : StreamInteractionModule, Object {
}
public async Entities.Message parse_message_stanza(Account account, Xmpp.MessageStanza message) {
- Entities.Message new_message = new Entities.Message(message.body);
+ string? body = message.body;
+ if (body != null) body = body.strip();
+ Entities.Message new_message = new Entities.Message(body);
new_message.account = account;
new_message.stanza_id = Xep.UniqueStableStanzaIDs.get_origin_id(message) ?? message.id;