Improve validation of mail account delegators

This commit is contained in:
Francis Lachapelle 2016-10-26 15:42:50 -04:00
parent 149997b4cd
commit 5027aabc1b

View file

@ -1059,11 +1059,9 @@ static NSString *inboxFolderName = @"INBOX";
{
currentDelegate = [oldDelegates objectAtIndex: count];
delegateUser = [SOGoUser userWithLogin: currentDelegate];
[delegates removeObject: currentDelegate];
if (delegateUser)
{
[delegates removeObject: currentDelegate];
[delegateUser removeMailDelegator: owner];
}
[delegateUser removeMailDelegator: owner];
}
[self _setDelegates: delegates];