Skip to content

Commit 13a8395

Browse files
Fix crash when opening chats with foreign users
Signed-off-by: Daniele Ricci <[email protected]>
1 parent ed5eb72 commit 13a8395

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

app/src/main/java/org/kontalk/authenticator/MyAccount.kt

+1-1
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ class MyAccount (val systemAccount: Account, private val accountManager: Account
6868
fun isSelfJID(bareJid: BareJid): Boolean = bareJid.equals(selfJID)
6969

7070
fun isNetworkJID(bareJid: BareJid): Boolean {
71-
return serverList.first { it.network.equals(bareJid.domain.toString(), true) } != null
71+
return serverList.firstOrNull { it.network.equals(bareJid.domain.toString(), true) } != null
7272
}
7373

7474
fun createLocalJID(localpart: String): String {

0 commit comments

Comments
 (0)