From 9cf1533f4ad2259ba6e66993273d96f5c89cab54 Mon Sep 17 00:00:00 2001 From: Erik Date: Fri, 22 Jun 2018 07:58:35 +0200 Subject: [PATCH] Reset recommendedBolus if we have a new prediction. This technically isn't necessary as they are updated in the same function but for consistency and not to forget during the next refactoring this is protecting the user from getting a potentially dangerous out of date recommendation. --- Loop/Managers/LoopDataManager.swift | 1 + 1 file changed, 1 insertion(+) diff --git a/Loop/Managers/LoopDataManager.swift b/Loop/Managers/LoopDataManager.swift index 2699c3881c..7120e9c3ec 100644 --- a/Loop/Managers/LoopDataManager.swift +++ b/Loop/Managers/LoopDataManager.swift @@ -165,6 +165,7 @@ final class LoopDataManager { fileprivate var predictedGlucose: [GlucoseValue]? { didSet { recommendedTempBasal = nil + recommendedBolus = nil } } fileprivate var retrospectivePredictedGlucose: [GlucoseValue]? {