From f1bd3fe76fc30b50af016c32777e32a409e1f20e Mon Sep 17 00:00:00 2001 From: Vittorio Morganti Date: Sun, 25 Oct 2020 22:39:21 +0100 Subject: [PATCH] Prioritise paid developer account over free If an account has both a free and paid developer account active concurrently, then the free account is preferred. Prefer the paid account for a longer signing period --- AltStore/Operations/AuthenticationOperation.swift | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/AltStore/Operations/AuthenticationOperation.swift b/AltStore/Operations/AuthenticationOperation.swift index 9a9252625..f732b170d 100644 --- a/AltStore/Operations/AuthenticationOperation.swift +++ b/AltStore/Operations/AuthenticationOperation.swift @@ -432,11 +432,11 @@ private extension AuthenticationOperation { func selectTeam(from teams: [ALTTeam]) { - if let team = teams.first(where: { $0.type == .free }) + if let team = teams.first(where: { $0.type == .individual }) { return completionHandler(.success(team)) } - else if let team = teams.first(where: { $0.type == .individual }) + else if let team = teams.first(where: { $0.type == .free }) { return completionHandler(.success(team)) }