isInSystemContacts should use systemName
This commit is contained in:
parent
f272433b7a
commit
56145fabcc
3 changed files with 20 additions and 2 deletions
|
@ -62,9 +62,13 @@ export default {
|
|||
onDeleteList: { action: true },
|
||||
onDistributionListCreated: { action: true },
|
||||
onHideMyStoriesFrom: { action: true },
|
||||
onMediaPlaybackStart: { action: true },
|
||||
onSend: { action: true },
|
||||
onViewersUpdated: { action: true },
|
||||
setMyStoriesToAllSignalConnections: { action: true },
|
||||
mostRecentActiveStoryTimestampByGroupOrDistributionList: {
|
||||
defaultValue: {},
|
||||
},
|
||||
signalConnections: {
|
||||
defaultValue: Array.from(Array(42), getDefaultConversation),
|
||||
},
|
||||
|
|
|
@ -4,9 +4,16 @@
|
|||
export const isInSystemContacts = ({
|
||||
type,
|
||||
name,
|
||||
systemGivenName,
|
||||
systemFamilyName,
|
||||
}: Readonly<{
|
||||
type?: string;
|
||||
name?: string;
|
||||
systemGivenName?: string;
|
||||
systemFamilyName?: string;
|
||||
}>): boolean =>
|
||||
// `direct` for redux, `private` for models and the database
|
||||
(type === 'direct' || type === 'private') && typeof name === 'string';
|
||||
(type === 'direct' || type === 'private') &&
|
||||
(typeof name === 'string' ||
|
||||
typeof systemGivenName === 'string' ||
|
||||
typeof systemFamilyName === 'string');
|
||||
|
|
|
@ -7,11 +7,13 @@ import { mapValues } from 'lodash';
|
|||
|
||||
import type { IPCType } from '../../window.d';
|
||||
import { parseIntWithFallback } from '../../util/parseIntWithFallback';
|
||||
import { getSignalConnections } from '../../util/getSignalConnections';
|
||||
import { UUIDKind } from '../../types/UUID';
|
||||
import { ThemeType } from '../../types/Util';
|
||||
import { getEnvironment, Environment } from '../../environment';
|
||||
import { SignalContext } from '../context';
|
||||
import * as log from '../../logging/log';
|
||||
import { formatCountForLogging } from '../../logging/formatCountForLogging';
|
||||
import * as Errors from '../../types/errors';
|
||||
|
||||
import { strictAssert } from '../../util/assert';
|
||||
|
@ -202,7 +204,12 @@ ipc.on('additional-log-data-request', async event => {
|
|||
const valueString = value && value !== 'TRUE' ? ` ${value}` : '';
|
||||
return `${enableString}${valueString}`;
|
||||
}),
|
||||
statistics,
|
||||
statistics: {
|
||||
...statistics,
|
||||
signalConnectionCount: formatCountForLogging(
|
||||
getSignalConnections().length
|
||||
),
|
||||
},
|
||||
user: {
|
||||
deviceId: window.textsecure.storage.user.getDeviceId(),
|
||||
e164: window.textsecure.storage.user.getNumber(),
|
||||
|
|
Loading…
Reference in a new issue