From d264c0089d5cf4b936906f377d47419deafdd1de Mon Sep 17 00:00:00 2001 From: Davide De Rosa Date: Thu, 11 Apr 2019 21:09:08 +0200 Subject: [PATCH] Pick random server number on simple selection --- Passepartout-iOS/Scenes/ProviderPoolViewController.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Passepartout-iOS/Scenes/ProviderPoolViewController.swift b/Passepartout-iOS/Scenes/ProviderPoolViewController.swift index 3151ea6a..48edf875 100644 --- a/Passepartout-iOS/Scenes/ProviderPoolViewController.swift +++ b/Passepartout-iOS/Scenes/ProviderPoolViewController.swift @@ -173,7 +173,7 @@ extension ProviderPoolViewController: UITableViewDataSource, UITableViewDelegate let model = models[indexPath.section] let group = model.sortedGroups[indexPath.row] let groupPools = model.poolsByGroup[group]! - guard let pool = groupPools.first else { + guard let pool = groupPools.randomElement() else { fatalError("Empty pools in group \(group)") } currentPool = pool