From 2957e4033cb9ce9f4854be620edc63817fd136ad Mon Sep 17 00:00:00 2001 From: another-simple-pixel Date: Sat, 16 May 2026 14:53:24 -0700 Subject: [PATCH] ChatInfoView: hide Servers section header when there is no server content When both chatSubStatus and cStats are null, the SectionView body rendered as empty (zero-height card) but the SERVERS title still appeared, leaving an orphan header between E2E encryption and Clear chat. Gate the whole section on having at least one of the two. --- .../kotlin/chat/simplex/common/views/chat/ChatInfoView.kt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/apps/multiplatform/common/src/commonMain/kotlin/chat/simplex/common/views/chat/ChatInfoView.kt b/apps/multiplatform/common/src/commonMain/kotlin/chat/simplex/common/views/chat/ChatInfoView.kt index 175d74361b..90eff9fbc1 100644 --- a/apps/multiplatform/common/src/commonMain/kotlin/chat/simplex/common/views/chat/ChatInfoView.kt +++ b/apps/multiplatform/common/src/commonMain/kotlin/chat/simplex/common/views/chat/ChatInfoView.kt @@ -636,9 +636,9 @@ fun ChatInfoLayout( SectionDividerSpaced(maxTopPadding = true) } - if (contact.ready && contact.active) { + val chatSubStatus = chatModel.chatSubStatus.value + if (contact.ready && contact.active && (chatSubStatus != null || cStats != null)) { SectionView(title = stringResource(MR.strings.conn_stats_section_title_servers)) { - val chatSubStatus = chatModel.chatSubStatus.value if (chatSubStatus != null) { SectionItemView({ AlertManager.shared.showAlertMsg(