mirror of
https://github.com/element-hq/element-android
synced 2024-11-27 11:59:12 +03:00
Do not fetch user if we do not have the previous content.
This commit is contained in:
parent
94a87744ac
commit
e3f5d15eaf
1 changed files with 2 additions and 1 deletions
|
@ -140,7 +140,8 @@ internal class RoomMemberEventHandler @Inject constructor(
|
||||||
val previousDisplayName = prevContent?.get("displayname") as? String
|
val previousDisplayName = prevContent?.get("displayname") as? String
|
||||||
val previousAvatar = prevContent?.get("avatar_url") as? String
|
val previousAvatar = prevContent?.get("avatar_url") as? String
|
||||||
|
|
||||||
if (previousDisplayName != roomMember.displayName || previousAvatar != roomMember.avatarUrl) {
|
if ((previousDisplayName != null && previousDisplayName != roomMember.displayName) ||
|
||||||
|
(previousAvatar != null && previousAvatar != roomMember.avatarUrl)) {
|
||||||
aggregator.userIdsToFetch.add(eventUserId)
|
aggregator.userIdsToFetch.add(eventUserId)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue