Supports refreshing apps with Siri on iOS 14

This commit is contained in:
Riley Testut
2020-09-08 12:29:44 -07:00
parent 3d9417c071
commit 0256079738
10 changed files with 669 additions and 321 deletions

View File

@@ -499,6 +499,17 @@ extension AppManager
}
}
extension AppManager
{
func backgroundRefresh(_ installedApps: [InstalledApp], presentsNotifications: Bool = true, completionHandler: @escaping (Result<[String: Result<InstalledApp, Error>], Error>) -> Void)
{
let backgroundRefreshAppsOperation = BackgroundRefreshAppsOperation(installedApps: installedApps)
backgroundRefreshAppsOperation.resultHandler = completionHandler
backgroundRefreshAppsOperation.presentsFinishedNotification = presentsNotifications
self.run([backgroundRefreshAppsOperation], context: nil)
}
}
private extension AppManager
{
enum AppOperation