[AltStoreCore] Fixes ALTAppPrivacyPermission.synthesizedName for legacy permissions

This commit is contained in:
Riley Testut
2023-10-10 15:29:34 -05:00
committed by Magesh K
parent 21b2a869a1
commit e33a40ecb1
5 changed files with 78 additions and 68 deletions

View File

@@ -1,31 +0,0 @@
//
// Regex+Permissions.swift
// AltStore
//
// Created by Riley Testut on 10/10/23.
// Copyright © 2023 Riley Testut. All rights reserved.
//
import RegexBuilder
@available(iOS 16, *)
extension Regex where Output == (Substring, Substring)
{
static var privacyPermission: some RegexComponent<(Substring, Substring)> {
Regex {
Optionally {
"NS"
}
// Capture permission "name"
Capture {
OneOrMore(.anyGraphemeCluster)
}
"UsageDescription"
// Optional suffix
Optionally(OneOrMore(.anyGraphemeCluster))
}
}
}