Skip to content

Commit

Permalink
Filter out groups from signal connections
Browse files Browse the repository at this point in the history
  • Loading branch information
josh-signal committed Aug 4, 2022
1 parent 7bc6bbc commit 41081cb
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion ts/util/getSignalConnections.ts
Expand Up @@ -5,11 +5,15 @@ import type { ConversationAttributesType } from '../model-types.d';
import type { ConversationModel } from '../models/conversations';
import type { ConversationType } from '../state/ducks/conversations';
import { isInSystemContacts } from './isInSystemContacts';
import { isDirectConversation } from './whatTypeOfConversation';

export function isSignalConnection(
conversation: ConversationType | ConversationAttributesType
): boolean {
return conversation.profileSharing || isInSystemContacts(conversation);
return (
isDirectConversation(conversation) &&
(conversation.profileSharing || isInSystemContacts(conversation))
);
}

export function getSignalConnections(): Array<ConversationModel> {
Expand Down

0 comments on commit 41081cb

Please sign in to comment.