diff --git a/app/src/main/java/com/android/calendar/alerts/AlertService.java b/app/src/main/java/com/android/calendar/alerts/AlertService.java index 38db5a31a642a914613ada2c2bcf0f3b8069ef8c..ccc5de3ad2025dcbaf488de4aa292cec37a447b3 100644 --- a/app/src/main/java/com/android/calendar/alerts/AlertService.java +++ b/app/src/main/java/com/android/calendar/alerts/AlertService.java @@ -529,15 +529,13 @@ public class AlertService extends Service { int newState = -1; boolean newAlert = false; - // Uncomment for the behavior of clearing out alerts after the - // events ended. b/1880369 - // - // if (endTime < currentTime) { - // newState = CalendarAlerts.DISMISSED; - // } else + // clearing out alerts after the events ended. b/1880369 + if (endTime < currentTime) { + newState = CalendarAlerts.STATE_DISMISSED; + } // Remove declined events - boolean sendAlert = !declined; + boolean sendAlert = !declined && newState != CalendarAlerts.STATE_DISMISSED; // Check for experimental reminder settings. if (remindRespondedOnly) { // If the experimental setting is turned on, then only send