fix: use ownerId for group DM detection in MainContent header

This commit is contained in:
Jannis Braun
2026-03-27 03:56:37 +01:00
parent 12d7fb365c
commit bbbbeaa955
@@ -83,7 +83,7 @@ export function MainContent() {
const dmChannel = dmChannels.find(dm => dm.id === currentChannelId); const dmChannel = dmChannels.find(dm => dm.id === currentChannelId);
const otherMembers = dmChannel?.members.filter(m => !isSelf(m, authUser)) ?? []; const otherMembers = dmChannel?.members.filter(m => !isSelf(m, authUser)) ?? [];
const isGroupDm = (dmChannel?.members.length ?? 0) > 2; const isGroupDm = !!dmChannel?.ownerId;
const firstOther = otherMembers[0]; const firstOther = otherMembers[0];
const { baseName: firstBaseName, domain: firstDomain } = parseFederatedUsername(firstOther?.username ?? ''); const { baseName: firstBaseName, domain: firstDomain } = parseFederatedUsername(firstOther?.username ?? '');
const dmName = isGroupDm const dmName = isGroupDm