Always use hardcoded team ID for release builds just in case

This commit is contained in:
Guilherme Rambo 2026-01-05 18:17:58 -03:00
parent b2cf6239b3
commit 8282002415
No known key found for this signature in database
GPG Key ID: 87A5DFB1FFAB6724

View File

@ -4,6 +4,7 @@ extension ProcessInfo {
private static let fallbackTeamID = "Z72PRUAWF6" private static let fallbackTeamID = "Z72PRUAWF6"
private static let teamID: String = { private static let teamID: String = {
#if DEBUG
guard let task = SecTaskCreateFromSelf(nil) else { guard let task = SecTaskCreateFromSelf(nil) else {
assertionFailure("SecTaskCreateFromSelf failed") assertionFailure("SecTaskCreateFromSelf failed")
return fallbackTeamID return fallbackTeamID
@ -15,6 +16,10 @@ extension ProcessInfo {
} }
return value return value
#else
/// Always use hardcoded team ID for release builds, just in case.
return fallbackTeamID
#endif
}() }()
public var teamID: String { Self.teamID } public var teamID: String { Self.teamID }