From dae6d6d521ca3298d71c0e92a1cac771d2a12902 Mon Sep 17 00:00:00 2001 From: Francis Lachapelle Date: Mon, 11 Apr 2022 16:42:34 -0400 Subject: [PATCH] fix(calendar): update calendar of all attendees when active user is not owner --- SoObjects/Appointments/SOGoAppointmentObject.m | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/SoObjects/Appointments/SOGoAppointmentObject.m b/SoObjects/Appointments/SOGoAppointmentObject.m index d6aeb9258..f0f5376db 100644 --- a/SoObjects/Appointments/SOGoAppointmentObject.m +++ b/SoObjects/Appointments/SOGoAppointmentObject.m @@ -898,10 +898,10 @@ { currentUID = [currentAttendee uidInContext: context]; if (currentUID) - [self _addOrUpdateEvent: newEvent - oldEvent: nil - forUID: currentUID - owner: owner]; + [self _addOrUpdateEvent: newEvent + oldEvent: nil + forUID: currentUID + owner: owner]; } return nil; @@ -1766,11 +1766,16 @@ inRecurrenceExceptionsForEvent: (iCalEvent *) theEvent } else { - // The organizer deletes an occurence. + // The organizer (or a user with sufficient rights) deletes an occurence currentUser = [context activeUser]; if (recurrenceId) - attendees = [occurence attendeesWithoutUser: currentUser]; + { + if (activeUserIsOwner) + attendees = [occurence attendeesWithoutUser: currentUser]; + else + attendees = [occurence attendeesWithoutUser: ownerUser]; + } else attendees = [[event parent] attendeesWithoutUser: currentUser];