mirror of
https://github.com/SideStore/SideStore.git
synced 2026-02-09 06:43:25 +01:00
[AltStoreCore] Fixes “any ALTAppPermission cannot conform to 'Hashable’” Xcode 15 compiler error
This commit is contained in:
@@ -195,10 +195,13 @@ open class MergePolicy: RSTRelationshipPreservingMergePolicy
|
|||||||
|
|
||||||
// Permissions
|
// Permissions
|
||||||
let contextPermissions = Set(contextApp._permissions.lazy.compactMap { $0 as? AppPermission }.map { AnyHashable($0.permission) })
|
let contextPermissions = Set(contextApp._permissions.lazy.compactMap { $0 as? AppPermission }.map { AnyHashable($0.permission) })
|
||||||
for case let databasePermission as AppPermission in databaseObject._permissions where !contextPermissions.contains(AnyHashable(databasePermission.permission))
|
for case let databasePermission as AppPermission in databaseObject._permissions /* where !contextPermissions.contains(AnyHashable(databasePermission.permission)) */ // Compiler error as of Xcode 15
|
||||||
{
|
{
|
||||||
// Permission does NOT exist in context, so delete existing databasePermission.
|
if !contextPermissions.contains(AnyHashable(databasePermission.permission))
|
||||||
databasePermission.managedObjectContext?.delete(databasePermission)
|
{
|
||||||
|
// Permission does NOT exist in context, so delete existing databasePermission.
|
||||||
|
databasePermission.managedObjectContext?.delete(databasePermission)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Versions
|
// Versions
|
||||||
|
|||||||
Reference in New Issue
Block a user