From 55bdaa2160b2d6dc7d3fd9b0f706dc053daa629c Mon Sep 17 00:00:00 2001 From: Narasimha-sc <166327228+Narasimha-sc@users.noreply.github.com> Date: Thu, 18 Jun 2026 11:06:55 +0000 Subject: [PATCH] ios: show pending invitee's received support messages in chat list preview Mirror the android/desktop fix: a pending invitee's received support message was dropped from the main chat list preview by the group itemTs comparison (received broker clock vs locally-stamped group-event clock - not comparable). Bypass the comparison when memberPending so the received support item surfaces in the preview. --- apps/ios/Shared/Model/ChatModel.swift | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/apps/ios/Shared/Model/ChatModel.swift b/apps/ios/Shared/Model/ChatModel.swift index 111dff382a..92c0b39db0 100644 --- a/apps/ios/Shared/Model/ChatModel.swift +++ b/apps/ios/Shared/Model/ChatModel.swift @@ -661,7 +661,11 @@ final class ChatModel: ObservableObject { chats[i].chatItems = switch cInfo { case .group: if let currentPreviewItem = chats[i].chatItems.first { - if cItem.meta.itemTs >= currentPreviewItem.meta.itemTs { + // For a pending invitee the support item (received via the broker clock) is the + // reason this preview updates; its itemTs isn't comparable to a locally-stamped + // group event, so always surface it rather than dropping it on a cross-clock check. + if cInfo.groupInfo?.membership.memberPending ?? false + || cItem.meta.itemTs >= currentPreviewItem.meta.itemTs { [cItem] } else { [currentPreviewItem]