From 5e1bbea5f023513c142f92de2ac33eafd264dd98 Mon Sep 17 00:00:00 2001 From: Daniel Gultsch Date: Fri, 20 Apr 2018 17:54:30 +0200 Subject: [PATCH] never use isStranger logic in conversation with self --- .../java/eu/siacs/conversations/entities/Conversation.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/main/java/eu/siacs/conversations/entities/Conversation.java b/src/main/java/eu/siacs/conversations/entities/Conversation.java index ce051cbb5..ae0a820a9 100644 --- a/src/main/java/eu/siacs/conversations/entities/Conversation.java +++ b/src/main/java/eu/siacs/conversations/entities/Conversation.java @@ -920,9 +920,11 @@ public class Conversation extends AbstractEntity implements Blockable, Comparabl } public boolean isWithStranger() { + final Contact contact = getContact(); return mode == MODE_SINGLE - && !getJid().equals(Jid.ofDomain(account.getJid().getDomain())) - && !getContact().showInRoster() + && !contactJid.equals(Jid.ofDomain(account.getJid().getDomain())) + && !contact.showInRoster() + && !contact.isSelf() && sentMessagesCount() == 0; }