aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/java/eu
diff options
context:
space:
mode:
authorDaniel Gultsch <daniel@gultsch.de>2015-12-09 12:18:06 +0100
committerDaniel Gultsch <daniel@gultsch.de>2015-12-09 12:18:06 +0100
commit5bd70cfee8d3a71cce5bfb0a1a3e3330091333a6 (patch)
tree2a78baca08925d20b169dd5ea45f96b7ef03d32a /src/main/java/eu
parent5e151c7311bed98ce7eafa041735484c32bd7dda (diff)
always show conversations with pending subscription requests
Diffstat (limited to 'src/main/java/eu')
-rw-r--r--src/main/java/eu/siacs/conversations/parser/PresenceParser.java8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/main/java/eu/siacs/conversations/parser/PresenceParser.java b/src/main/java/eu/siacs/conversations/parser/PresenceParser.java
index d9806dfc..d27182c1 100644
--- a/src/main/java/eu/siacs/conversations/parser/PresenceParser.java
+++ b/src/main/java/eu/siacs/conversations/parser/PresenceParser.java
@@ -200,10 +200,12 @@ public class PresenceParser extends AbstractParser implements
mPresenceGenerator.sendPresenceUpdatesTo(contact));
} else {
contact.setOption(Contact.Options.PENDING_SUBSCRIPTION_REQUEST);
+ final Conversation conversation = mXmppConnectionService.findOrCreateConversation(
+ account, contact.getJid().toBareJid(), false);
final String statusMessage = packet.findChildContent("status");
- if (statusMessage != null && !statusMessage.isEmpty()) {
- final Conversation conversation = mXmppConnectionService.findOrCreateConversation(
- account, contact.getJid().toBareJid(), false);
+ if (statusMessage != null
+ && !statusMessage.isEmpty()
+ && conversation.countMessages() == 0) {
conversation.add(new Message(
conversation,
statusMessage,