diff --git a/ChangeLog b/ChangeLog index 6c1d3cd39..518998723 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2008-05-22 Wolfgang Sourdeau + + * SoObjects/Mailer/SOGoDraftObject.m ([SOGoDraftObject + -sendMail]): the email passed as parameter to sendmail is now the + bare user email. + 2008-05-21 Wolfgang Sourdeau * UI/MailerUI/UIxMailFolderActions.m ([UIxMailFolderActions diff --git a/SoObjects/Mailer/SOGoDraftObject.m b/SoObjects/Mailer/SOGoDraftObject.m index ae5e8137c..10f45b944 100644 --- a/SoObjects/Mailer/SOGoDraftObject.m +++ b/SoObjects/Mailer/SOGoDraftObject.m @@ -1269,6 +1269,21 @@ static BOOL showTextAttachmentsInline = NO; return allRecipients; } +- (NSArray *) allBareRecipients +{ + NSMutableArray *bareRecipients; + NSEnumerator *allRecipients; + NSString *recipient; + + bareRecipients = [NSMutableArray array]; + + allRecipients = [[self allRecipients] objectEnumerator]; + while ((recipient = [allRecipients nextObject])) + [bareRecipients addObject: [recipient pureEMailAddress]]; + + return bareRecipients; +} + - (NSException *) sendMail { NSException *error; @@ -1284,7 +1299,7 @@ static BOOL showTextAttachmentsInline = NO; { message = [self mimeMessageAsData]; error = [[SOGoMailer sharedMailer] sendMailData: message - toRecipients: [self allRecipients] + toRecipients: [self allBareRecipients] sender: [self sender]]; if (!error) {