App: Improve auto update behaviour

This commit is contained in:
2024-03-21 10:23:44 +01:00
parent afc143e1e4
commit 87da56b7a9
2 changed files with 6 additions and 1 deletions

View File

@@ -104,6 +104,9 @@ namespace Elwig {
try {
await AppDbUpdater.CheckDb();
} catch (Exception e) {
if (Config.UpdateUrl != null && Utils.HasInternetConnectivity()) {
await CheckForUpdates();
}
MessageBox.Show($"Invalid Database:\n\n{e.Message}", "Invalid Database", MessageBoxButton.OK, MessageBoxImage.Error);
Shutdown();
return;