|
|
@@ -33,7 +33,10 @@ extension GlucoseStored {
|
|
|
|
|
|
let firstValue = glucose.first?.glucose
|
|
|
|
|
|
- return glucose.allSatisfy { $0.glucose == firstValue && $0.glucose == 400 }
|
|
|
+ /// 400 mg/dL covers all Dexcom CGMs as well as European Libre 2 and most readings from xDrip4iOS.
|
|
|
+ /// U.S. / Canadian Libres can emit up to 500 mg/dL until it reads "HI"
|
|
|
+ /// Our condition considers both these values, 400 and 500, as possible "flat" readings when paired CGM reads HIGH.
|
|
|
+ return glucose.allSatisfy { $0.glucose == firstValue && ($0.glucose == 400 || $0.glucose == 500) }
|
|
|
}
|
|
|
|
|
|
// Preview
|