Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions Common/FeatureFlags.swift
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ struct FeatureFlagConfiguration: Decodable {
let simulatedCoreDataEnabled: Bool
let walshInsulinModelEnabled: Bool
let siriEnabled: Bool
let automaticBolusEnabled: Bool

fileprivate init() {
#if CGM_MANAGER_CATEGORIZE_GLUCOSE_RANGE_ENABLED
Expand Down Expand Up @@ -127,6 +128,13 @@ struct FeatureFlagConfiguration: Decodable {
#else
self.siriEnabled = true
#endif

// Swift compiler config is inverse, since the default state is enabled.
#if AUTOMATIC_BOLUS_DISABLED
self.automaticBolusEnabled = false
#else
self.automaticBolusEnabled = true
#endif
}
}

Expand All @@ -149,6 +157,7 @@ extension FeatureFlagConfiguration : CustomDebugStringConvertible {
"* simulatedCoreDataEnabled: \(simulatedCoreDataEnabled)",
"* walshInsulinModelEnabled: \(walshInsulinModelEnabled)",
"* siriEnabled: \(siriEnabled)",
"* automaticBolusEnabled: \(automaticBolusEnabled)"
].joined(separator: "\n")
}
}
Loading