Rethrows Core Data save errors after installing apps vs ignoring

This commit is contained in:
Riley Testut
2024-02-15 17:42:22 -06:00
committed by Magesh K
parent aa655fc5a3
commit 8ba28d0cd4

View File

@@ -2188,8 +2188,15 @@ private extension AppManager
WidgetCenter.shared.reloadAllTimelines()
do { try installedApp.managedObjectContext?.save() }
catch { print("Error saving installed app.", error) }
do
{
try installedApp.managedObjectContext?.save()
}
catch
{
Logger.main.error("Failed to save InstalledApp to database. \(error.localizedDescription, privacy: .public)")
throw error
}
}
catch let nsError as NSError
{