From 51647fef95d27790a9d1e79be2d92ba3f6bb2b8f Mon Sep 17 00:00:00 2001 From: yash-signal Date: Wed, 2 Apr 2025 13:52:21 -0500 Subject: [PATCH] Fix avatar not showing for new group adds with trusted contact --- ts/groups.ts | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/ts/groups.ts b/ts/groups.ts index c5d8427d4e..0e0c283149 100644 --- a/ts/groups.ts +++ b/ts/groups.ts @@ -5898,16 +5898,6 @@ async function applyGroupState({ result.name = undefined; } - // avatar - result = { - ...result, - ...(await applyNewAvatar({ - newAvatarUrl: dropNull(groupState.avatar), - attributes: result, - logId, - })), - }; - // disappearingMessagesTimer // Note: during decryption, disappearingMessageTimer becomes a GroupAttributeBlob const { disappearingMessagesTimer } = groupState; @@ -6131,6 +6121,16 @@ async function applyGroupState({ return member; }); + // avatar + result = { + ...result, + ...(await applyNewAvatar({ + newAvatarUrl: dropNull(groupState.avatar), + attributes: result, + logId, + })), + }; + if (result.left) { result.addedBy = undefined; }