From 19bc2b627f01047039c6ffc18e933f8f1606ebca Mon Sep 17 00:00:00 2001 From: tibbi Date: Sun, 5 Mar 2017 21:22:24 +0100 Subject: [PATCH] handle all reminder periods properly --- .../kotlin/com/simplemobiletools/calendar/extensions/Context.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/src/main/kotlin/com/simplemobiletools/calendar/extensions/Context.kt b/app/src/main/kotlin/com/simplemobiletools/calendar/extensions/Context.kt index c9839c2bf..34b91e17e 100644 --- a/app/src/main/kotlin/com/simplemobiletools/calendar/extensions/Context.kt +++ b/app/src/main/kotlin/com/simplemobiletools/calendar/extensions/Context.kt @@ -54,7 +54,7 @@ fun Context.scheduleNextEventReminder(event: Event) { reminderSeconds.forEach { var startTS = event.startTS - it if (event.repeatInterval == DAY || event.repeatInterval == WEEK || event.repeatInterval == BIWEEK) { - while (startTS < now || event.ignoreEventOccurrences.contains(startTS)) { + while (startTS < now || event.ignoreEventOccurrences.contains(startTS + it)) { startTS += event.repeatInterval } nextTS = Math.min(nextTS, startTS)