Don't show name collisions for system contacts
This commit is contained in:
parent
84be8288e9
commit
6c6eed0b1e
12 changed files with 121 additions and 17 deletions
12
ts/util/isInSystemContacts.ts
Normal file
12
ts/util/isInSystemContacts.ts
Normal file
|
@ -0,0 +1,12 @@
|
|||
// Copyright 2021 Signal Messenger, LLC
|
||||
// SPDX-License-Identifier: AGPL-3.0-only
|
||||
|
||||
export const isInSystemContacts = ({
|
||||
type,
|
||||
name,
|
||||
}: Readonly<{
|
||||
type?: string;
|
||||
name?: string;
|
||||
}>): boolean =>
|
||||
// `direct` for redux, `private` for models and the database
|
||||
(type === 'direct' || type === 'private') && typeof name === 'string';
|
Loading…
Add table
Add a link
Reference in a new issue