mirror of
https://github.com/oxen-io/session-android.git
synced 2024-12-28 02:37:46 +00:00
handle the case when an added member is a zombie
This commit is contained in:
parent
bfa75a3db9
commit
9399da6bad
@ -395,6 +395,11 @@ private fun MessageReceiver.handleClosedGroupMembersAdded(message: ClosedGroupCo
|
||||
val newMembers = members + updateMembers
|
||||
storage.updateMembers(groupID, newMembers.map { Address.fromSerialized(it) })
|
||||
|
||||
// update zombie members in case the added members are zombies
|
||||
val zombies = storage.getZombieMember(groupID)
|
||||
if (zombies.intersect(updateMembers).isNotEmpty())
|
||||
storage.updateZombieMembers(groupID, zombies.minus(updateMembers).map { Address.fromSerialized(it) })
|
||||
|
||||
// Notify the user
|
||||
if (userPublicKey == senderPublicKey) {
|
||||
// sender is a linked device
|
||||
|
Loading…
x
Reference in New Issue
Block a user