diff --git a/LoopFollow/Remote/LoopAPNS/LoopCarbEditSheet.swift b/LoopFollow/Remote/LoopAPNS/LoopCarbEditSheet.swift index 2fd82cabc..fdf10c8f8 100644 --- a/LoopFollow/Remote/LoopAPNS/LoopCarbEditSheet.swift +++ b/LoopFollow/Remote/LoopAPNS/LoopCarbEditSheet.swift @@ -160,6 +160,7 @@ struct LoopCarbEditSheet: View { } private func validateAndConfirm() { + guard alertType == nil else { return } guard carbsAmount.doubleValue(for: .gram()) > 0 else { alertType = .validation("Enter a carb amount, or use Delete carbs to remove the entry.") return diff --git a/LoopFollow/Remote/TRC/TRCMealEditView.swift b/LoopFollow/Remote/TRC/TRCMealEditView.swift index 06cb8fa67..9da718162 100644 --- a/LoopFollow/Remote/TRC/TRCMealEditView.swift +++ b/LoopFollow/Remote/TRC/TRCMealEditView.swift @@ -90,6 +90,7 @@ struct TRCMealEditView: View { fatFocused = false proteinFocused = false DispatchQueue.main.asyncAfter(deadline: .now() + 0.1) { + guard alertType == nil else { return } guard carbsValue > 0 || fatValue > 0 || proteinValue > 0 else { alertType = .validation("Enter at least one of carbs, fat, or protein. Use Delete meal to remove the meal.") return