Move cleanupOrphanedAttachments before restart

pull/948/head
Konstantin Ullrich 5 years ago
parent 370467a127
commit 1a9206fdbe

@ -398,6 +398,13 @@
await storage.put('version', currentVersion);
if (newVersion) {
await window.Signal.Data.cleanupOrphanedAttachments();
window.log.info(
`New version detected: ${currentVersion}; previous: ${lastVersion}`
);
if (
lastVersion &&
window.isBeforeVersion(lastVersion, 'v1.15.0-beta.5')
@ -405,10 +412,6 @@
await window.Signal.Logs.deleteAll();
window.restart();
}
window.log.info(
`New version detected: ${currentVersion}; previous: ${lastVersion}`
);
}
if (isIndexedDBPresent) {
@ -431,10 +434,6 @@
Views.Initialization.setMessage(window.i18n('optimizingApplication'));
if (newVersion) {
await window.Signal.Data.cleanupOrphanedAttachments();
}
Views.Initialization.setMessage(window.i18n('loading'));
idleDetector = new IdleDetector();

Loading…
Cancel
Save