mirror of
https://github.com/moparisthebest/Conversations
synced 2024-11-28 11:42:15 -05:00
improvements on findConversation
This commit is contained in:
parent
161623eca2
commit
f256a466d8
@ -922,9 +922,9 @@ public class XmppConnectionService extends Service {
|
|||||||
public Conversation find(List<Conversation> haystack, Account account,
|
public Conversation find(List<Conversation> haystack, Account account,
|
||||||
String jid) {
|
String jid) {
|
||||||
for (Conversation conversation : haystack) {
|
for (Conversation conversation : haystack) {
|
||||||
if ((account == null || conversation.getAccount().equals(account))
|
if ((account == null || conversation.getAccount() == account)
|
||||||
&& (conversation.getContactJid().split("/", 2)[0]
|
&& (conversation.getContactJid().split("/", 2)[0]
|
||||||
.equals(jid))) {
|
.equalsIgnoreCase(jid))) {
|
||||||
return conversation;
|
return conversation;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user