diff --git a/Sources/mas/AppStore/Downloader.swift b/Sources/mas/AppStore/Downloader.swift index 5f90035..7e0b338 100644 --- a/Sources/mas/AppStore/Downloader.swift +++ b/Sources/mas/AppStore/Downloader.swift @@ -19,7 +19,7 @@ import StoreFoundation /// the promise is rejected with the first error, after all remaining downloads are attempted. func downloadAll(_ appIDs: [AppID], purchase: Bool = false) -> Promise { var firstError: Error? - return appIDs.reduce(Guarantee.value(())) { previous, appID in + return appIDs.reduce(Guarantee.value(())) { previous, appID in previous.then { downloadWithRetries(appID, purchase: purchase).recover { error in if firstError == nil { diff --git a/Sources/mas/AppStore/ISStoreAccount.swift b/Sources/mas/AppStore/ISStoreAccount.swift index 7dcfd30..7758ea4 100644 --- a/Sources/mas/AppStore/ISStoreAccount.swift +++ b/Sources/mas/AppStore/ISStoreAccount.swift @@ -14,7 +14,7 @@ extension ISStoreAccount: StoreAccount { static var primaryAccount: Promise { if #available(macOS 10.13, *) { return race( - Promise { seal in + Promise { seal in ISServiceProxy.genericShared().accountService.primaryAccount { storeAccount in seal.fulfill(storeAccount) }