diff options
Diffstat (limited to 'Map/Business/Stage.swift')
| -rw-r--r-- | Map/Business/Stage.swift | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/Map/Business/Stage.swift b/Map/Business/Stage.swift index ebee17f..4962f8f 100644 --- a/Map/Business/Stage.swift +++ b/Map/Business/Stage.swift @@ -153,8 +153,7 @@ struct Stage: Codable { if let customStagesData = UserDefaults.standard.data(forKey: "customStages"), let customStagesList = try? JSONDecoder().decode( [CustomStage].self, from: customStagesData), - let customStage = customStagesList.first(where: { $0.id == uuid }) - { + let customStage = customStagesList.first(where: { $0.id == uuid }) { return customStage.stage } return stages(.behavior) // fallback @@ -207,8 +206,7 @@ struct Stage: Codable { if let customStagesData = UserDefaults.standard.data(forKey: "customStages"), let customStagesList = try? JSONDecoder().decode( [CustomStage].self, from: customStagesData), - let customStage = customStagesList.first(where: { $0.id == uuid }) - { + let customStage = customStagesList.first(where: { $0.id == uuid }) { return customStage.name } return String(localized: "stage_type.behavior") // fallback @@ -273,13 +271,12 @@ enum StageType: Identifiable, Equatable { static let properties: [StageType] = [ .market, .knowledgeManagement, .marketPerception, .userPerception, .perceptionInIndustry, .focusOfValue, .understanding, .comparison, .failure, - .marketAction, .efficiency, .decisionDrivers, + .marketAction, .efficiency, .decisionDrivers ] static var customStages: [StageType] { if let customStagesData = UserDefaults.standard.data(forKey: "customStages"), - let customStagesList = try? JSONDecoder().decode([CustomStage].self, from: customStagesData) - { + let customStagesList = try? JSONDecoder().decode([CustomStage].self, from: customStagesData) { return customStagesList.map { .custom($0.id) } } return [] |