Fix time conflict validation when not owner

pull/245/head
Francis Lachapelle 2018-10-22 12:08:46 -04:00
parent 59c3bdc242
commit 35ea86557c
2 changed files with 16 additions and 1 deletions

6
NEWS
View File

@ -1,3 +1,9 @@
4.X.Y (2018-MM-DD)
------------------
Bug fixes
- [web] fixed time conflict validation when not the owner
4.0.3 (2018-10-17)
------------------

View File

@ -718,6 +718,7 @@
}
// Find the attendee associated to the current UID
currentAttendee = nil;
for (i = 0; i < [theAttendees count]; i++)
{
currentAttendee = [theAttendees objectAtIndex: i];
@ -783,6 +784,7 @@
NSMutableDictionary *info;
NSMutableArray *conflicts;
NSString *formattedEnd;
SOGoUser *ownerUser;
id o;
info = [NSMutableDictionary dictionary];
@ -792,10 +794,17 @@
{
if ([currentAttendee cn])
[info setObject: [currentAttendee cn] forKey: @"attendee_name"];
if ([currentAttendee rfc822Email])
[info setObject: [currentAttendee rfc822Email] forKey: @"attendee_email"];
}
else if ([owner isEqualToString: currentUID])
{
ownerUser = [SOGoUser userWithLogin: owner];
if ([ownerUser cn])
[info setObject: [ownerUser cn] forKey: @"attendee_name"];
if ([ownerUser systemEmail])
[info setObject: [ownerUser systemEmail] forKey: @"attendee_email"];
}
for (i = 0; i < [fbInfo count]; i++)
{