[Messaging] Delete empty threads after message deletion import (#3716)

* [Messaging] Delete empty threads after message deletion import

* fix
This commit is contained in:
Weiko
2024-02-02 18:13:41 +01:00
committed by GitHub
parent c56153cab1
commit 729e2dc651
12 changed files with 334 additions and 158 deletions

View File

@ -52,8 +52,8 @@ export class GmailFullSyncService {
const gmailMessageChannel =
await this.messageChannelService.getFirstByConnectedAccountIdOrFail(
workspaceId,
connectedAccountId,
workspaceId,
);
const gmailMessageChannelId = gmailMessageChannel.id;
@ -129,7 +129,7 @@ export class GmailFullSyncService {
if (!historyId) throw new Error('No history id found');
await this.connectedAccountService.saveLastSyncHistoryId(
await this.connectedAccountService.updateLastSyncHistoryId(
historyId,
connectedAccount.id,
workspaceId,