Ensure that delete logs timeout does not run after resolution

This commit is contained in:
Josh Perez 2021-09-20 20:25:29 -04:00 committed by GitHub
parent 4e43459d34
commit 4e6c415ad8
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 13 additions and 16 deletions

View file

@ -102,6 +102,7 @@ import {
loadRecentEmojis,
getEmojiReducerState,
} from './util/loadRecentEmojis';
import { deleteAllLogs } from './util/deleteAllLogs';
const MAX_ATTACHMENT_DOWNLOAD_AGE = 3600 * 72 * 1000;
@ -749,7 +750,7 @@ export async function startApp(): Promise<void> {
// This one should always be last - it could restart the app
if (window.isBeforeVersion(lastVersion, 'v1.15.0-beta.5')) {
await window.Signal.Logs.deleteAll();
await deleteAllLogs();
window.restart();
return;
}