Skip to content

Commit

Permalink
fix: Update AvatarView state when AvatarDisplayType is USER_AVATAR
Browse files Browse the repository at this point in the history
  • Loading branch information
TommyDL-Infomaniak committed Feb 26, 2025
1 parent 0c8fbb3 commit 0a29ad0
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion app/src/main/java/com/infomaniak/mail/views/AvatarView.kt
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,10 @@ class AvatarView @JvmOverloads constructor(
) {
when (avatarDisplayType) {
AvatarDisplayType.UNKNOWN_CORRESPONDENT -> loadUnknownUserAvatar()
AvatarDisplayType.USER_AVATAR -> AccountUtils.currentUser?.let { loadAvatar(user = it) }
AvatarDisplayType.USER_AVATAR -> {
state.update(correspondent, bimi)
AccountUtils.currentUser?.let { loadAvatar(user = it) }
}
AvatarDisplayType.CUSTOM_AVATAR,
AvatarDisplayType.INITIALS -> loadAvatarUsingDictionary(correspondent!!, contacts, bimi)
AvatarDisplayType.BIMI -> loadBimiAvatar(correspondent!!, bimi!!)
Expand Down

0 comments on commit 0a29ad0

Please sign in to comment.