Fix #1385, cancel notification and pending intent if event is deleted for future occurrences

This commit is contained in:
tanvir-ahmod 2021-06-12 20:26:37 +06:00
parent 5aa35bfe7a
commit 3fcc23a320
1 changed files with 2 additions and 1 deletions

View File

@ -181,7 +181,8 @@ class EventsHelper(val context: Context) {
fun addEventRepeatLimit(eventId: Long, limitTS: Long) {
val time = Formatter.getDateTimeFromTS(limitTS)
eventsDB.updateEventRepetitionLimit(limitTS - time.hourOfDay, eventId)
context.cancelNotification(eventId)
context.cancelPendingIntent(eventId)
if (config.caldavSync) {
val event = eventsDB.getEventWithId(eventId)
if (event?.getCalDAVCalendarId() != 0) {