aboutsummaryrefslogtreecommitdiffstats
path: root/src/main
diff options
context:
space:
mode:
authorDaniel Gultsch <daniel@gultsch.de>2015-06-02 06:23:32 +0200
committerDaniel Gultsch <daniel@gultsch.de>2015-06-02 06:23:32 +0200
commitdf86b0fc47cb7af8e97826f97d0e202405cff414 (patch)
tree914824fcb4af8f25a60220c45eb6f838489a3d24 /src/main
parenta577ec7c318d734de3ed8c2dc5ab1dd4b773b78a (diff)
improved compatibility with muc components that change the message id
Diffstat (limited to '')
-rw-r--r--src/main/java/eu/siacs/conversations/parser/MessageParser.java5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/main/java/eu/siacs/conversations/parser/MessageParser.java b/src/main/java/eu/siacs/conversations/parser/MessageParser.java
index 898613e3..fe42a2ae 100644
--- a/src/main/java/eu/siacs/conversations/parser/MessageParser.java
+++ b/src/main/java/eu/siacs/conversations/parser/MessageParser.java
@@ -269,9 +269,10 @@ public class MessageParser extends AbstractParser implements
status = Message.STATUS_SEND;
if (mXmppConnectionService.markMessage(conversation, remoteMsgId, Message.STATUS_SEND_RECEIVED)) {
return;
- } else if (remoteMsgId == null) {
- Message message = conversation.findSentMessageWithBody(packet.getBody());
+ } else {
+ Message message = conversation.findSentMessageWithBody(body);
if (message != null) {
+ message.setRemoteMsgId(remoteMsgId);
mXmppConnectionService.markMessage(message, Message.STATUS_SEND_RECEIVED);
return;
}