mirror of
https://github.com/SideStore/SideStore.git
synced 2026-02-10 23:33:29 +01:00
Removes support for “background mode” permissions
This commit is contained in:
@@ -23,7 +23,6 @@ public class AppPermission: NSManagedObject, Decodable, Fetchable
|
||||
{
|
||||
case .entitlement: return ALTEntitlement(rawValue: self._permission)
|
||||
case .privacy: return ALTAppPrivacyPermission(rawValue: self._permission)
|
||||
case .backgroundMode: return ALTAppBackgroundMode(rawValue: self._permission)
|
||||
default: return UnknownAppPermission(rawValue: self._permission)
|
||||
}
|
||||
}
|
||||
@@ -44,7 +43,6 @@ public class AppPermission: NSManagedObject, Decodable, Fetchable
|
||||
{
|
||||
case entitlement
|
||||
case privacyType = "privacy"
|
||||
case backgroundMode = "background"
|
||||
|
||||
case usageDescription
|
||||
}
|
||||
@@ -71,11 +69,6 @@ public class AppPermission: NSManagedObject, Decodable, Fetchable
|
||||
self._permission = privacyType
|
||||
self.type = .privacy
|
||||
}
|
||||
else if let backgroundMode = try container.decodeIfPresent(String.self, forKey: .backgroundMode)
|
||||
{
|
||||
self._permission = backgroundMode
|
||||
self.type = .backgroundMode
|
||||
}
|
||||
else
|
||||
{
|
||||
self._permission = ""
|
||||
|
||||
@@ -16,7 +16,6 @@ public extension ALTAppPermissionType
|
||||
case .unknown: return NSLocalizedString("Permission", comment: "")
|
||||
case .entitlement: return NSLocalizedString("Entitlement", comment: "")
|
||||
case .privacy: return NSLocalizedString("Privacy Permission", comment: "")
|
||||
case .backgroundMode: return NSLocalizedString("Background Mode", comment: "")
|
||||
default: return nil
|
||||
}
|
||||
}
|
||||
@@ -150,14 +149,3 @@ extension ALTAppPrivacyPermission: ALTAppPermission
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
extension ALTAppBackgroundMode: ALTAppPermission
|
||||
{
|
||||
public var type: ALTAppPermissionType { .backgroundMode }
|
||||
public var symbolName: String? { nil }
|
||||
|
||||
public var localizedName: String? { nil }
|
||||
public var synthesizedName: String? { nil }
|
||||
|
||||
public var localizedDescription: String? { nil }
|
||||
}
|
||||
|
||||
@@ -12,11 +12,8 @@ typedef NSString *ALTAppPermissionType NS_TYPED_EXTENSIBLE_ENUM;
|
||||
extern ALTAppPermissionType const ALTAppPermissionTypeUnknown;
|
||||
extern ALTAppPermissionType const ALTAppPermissionTypeEntitlement;
|
||||
extern ALTAppPermissionType const ALTAppPermissionTypePrivacy;
|
||||
extern ALTAppPermissionType const ALTAppPermissionTypeBackgroundMode;
|
||||
|
||||
typedef NSString *ALTAppPrivacyPermission NS_TYPED_EXTENSIBLE_ENUM;
|
||||
typedef NSString *ALTAppBackgroundMode NS_TYPED_EXTENSIBLE_ENUM;
|
||||
|
||||
extern ALTAppPrivacyPermission const ALTAppPrivacyPermissionAppleMusic;
|
||||
extern ALTAppPrivacyPermission const ALTAppPrivacyPermissionBluetooth;
|
||||
extern ALTAppPrivacyPermission const ALTAppPrivacyPermissionCalendars;
|
||||
|
||||
@@ -11,7 +11,6 @@
|
||||
ALTAppPermissionType const ALTAppPermissionTypeUnknown = @"unknown";
|
||||
ALTAppPermissionType const ALTAppPermissionTypeEntitlement = @"entitlement";
|
||||
ALTAppPermissionType const ALTAppPermissionTypePrivacy = @"privacy";
|
||||
ALTAppPermissionType const ALTAppPermissionTypeBackgroundMode = @"background";
|
||||
|
||||
ALTAppPrivacyPermission const ALTAppPrivacyPermissionAppleMusic = @"AppleMusic";
|
||||
ALTAppPrivacyPermission const ALTAppPrivacyPermissionBluetooth = @"BluetoothAlways";
|
||||
|
||||
Reference in New Issue
Block a user