From dc49421ff5843a4c529bbd61fe83538c5171f8d9 Mon Sep 17 00:00:00 2001 From: Boris Grozev Date: Wed, 11 Dec 2024 14:14:05 -0600 Subject: [PATCH] fix: Suppress log when participant leaves. --- .../kotlin/org/jitsi/jicofo/xmpp/muc/ChatRoomMemberImpl.kt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/jicofo-common/src/main/kotlin/org/jitsi/jicofo/xmpp/muc/ChatRoomMemberImpl.kt b/jicofo-common/src/main/kotlin/org/jitsi/jicofo/xmpp/muc/ChatRoomMemberImpl.kt index 49aa6b4233..fd4545daee 100644 --- a/jicofo-common/src/main/kotlin/org/jitsi/jicofo/xmpp/muc/ChatRoomMemberImpl.kt +++ b/jicofo-common/src/main/kotlin/org/jitsi/jicofo/xmpp/muc/ChatRoomMemberImpl.kt @@ -185,7 +185,9 @@ class ChatRoomMemberImpl( var newRole: MemberRole = MemberRole.VISITOR chatRoom.getOccupant(this)?.let { newRole = fromSmack(it.role, it.affiliation) } - if (!firstPresence && (role == MemberRole.VISITOR) != (newRole == MemberRole.VISITOR)) { + if (!firstPresence && presence.type != Presence.Type.unavailable && + (role == MemberRole.VISITOR) != (newRole == MemberRole.VISITOR) + ) { // This will mess up various member counts // TODO: Should we try to update them, instead? logger.warn("Member role changed from $role to $newRole - not supported!")