From f91e2c4edd96ac28e3e7bfe2caaddf37d4c40cd3 Mon Sep 17 00:00:00 2001 From: warrickct Date: Wed, 24 Nov 2021 13:55:16 +1100 Subject: [PATCH] Minor PR fixes --- ts/components/session/LeftPaneMessageSection.tsx | 7 ++----- ts/receiver/callMessage.ts | 2 +- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/ts/components/session/LeftPaneMessageSection.tsx b/ts/components/session/LeftPaneMessageSection.tsx index 848651b30..4c2c56b00 100644 --- a/ts/components/session/LeftPaneMessageSection.tsx +++ b/ts/components/session/LeftPaneMessageSection.tsx @@ -82,12 +82,9 @@ export class LeftPaneMessageSection extends React.Component { throw new Error('renderRow: Tried to render without conversations'); } - let conversation; - if (conversations?.length) { - conversation = conversations[index]; - } - + const conversation = conversations[index]; if (!conversation) { + window?.log?.info('No conversation found at index'); return null; } diff --git a/ts/receiver/callMessage.ts b/ts/receiver/callMessage.ts index bec8f2f6b..3670670fb 100644 --- a/ts/receiver/callMessage.ts +++ b/ts/receiver/callMessage.ts @@ -2,7 +2,7 @@ import _ from 'lodash'; import { SignalService } from '../protobuf'; import { TTL_DEFAULT } from '../session/constants'; import { SNodeAPI } from '../session/snode_api'; -import { CallManager, UserUtils } from '../session/utils'; +import { CallManager } from '../session/utils'; import { removeFromCache } from './cache'; import { EnvelopePlus } from './types';