mirror of
https://github.com/SideStore/SideStore.git
synced 2026-02-20 04:03:26 +01:00
Ignores recommended sources permission errors for RELEASE builds
This commit is contained in:
@@ -338,21 +338,18 @@ private extension VerifyAppOperation
|
|||||||
}
|
}
|
||||||
catch let error as VerificationError where error.code == .undeclaredPermissions
|
catch let error as VerificationError where error.code == .undeclaredPermissions
|
||||||
{
|
{
|
||||||
#if !BETA
|
|
||||||
throw error
|
|
||||||
#endif
|
|
||||||
|
|
||||||
if let recommendedSources = UserDefaults.shared.recommendedSources, let (sourceID, sourceURL) = await $storeApp.perform({ $0.source.map { ($0.identifier, $0.sourceURL) } })
|
if let recommendedSources = UserDefaults.shared.recommendedSources, let (sourceID, sourceURL) = await $storeApp.perform({ $0.source.map { ($0.identifier, $0.sourceURL) } })
|
||||||
{
|
{
|
||||||
let normalizedSourceURL = try? sourceURL.normalized()
|
let normalizedSourceURL = try? sourceURL.normalized()
|
||||||
|
|
||||||
let isRecommended = recommendedSources.contains { $0.identifier == sourceID || (try? $0.sourceURL?.normalized()) == normalizedSourceURL }
|
let isRecommended = recommendedSources.contains { $0.identifier == sourceID || (try? $0.sourceURL?.normalized()) == normalizedSourceURL }
|
||||||
guard !isRecommended else {
|
guard !isRecommended else {
|
||||||
// Don't enforce permission checking for Recommended Sources while 2.0 is in beta.
|
// Don't enforce permission checking for Recommended Sources for now.
|
||||||
return localPermissions
|
return localPermissions
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
throw error
|
||||||
}
|
}
|
||||||
|
|
||||||
return localPermissions
|
return localPermissions
|
||||||
|
|||||||
Reference in New Issue
Block a user