Kept the app responsive while a backup copies the index (#1062)

This commit is contained in:
Thorsten Sommer authored and GitHub committed 2026-10-15 17:50:44 +02:00
1 parent 936043319c
commit 65857ca845
5 files changed
+64 -28

No files matched your search

@@ -324,7 +324,8 @@ public sealed class DataRestoreService(ILogger<DataRestoreService> logger, Setti
var target = this.CreateTarget();
try
{
DataRestorePreparer.Discard(target);
// The unpacked backup may hold thousands of files, and the click to discard it arrives on the thread of the user interface:
await Task.Run(() => DataRestorePreparer.Discard(target));
logger.LogInformation("Discarded the prepared restore.");
}
finally