Hi, I just create a JIRA[1] and submitted a quick fix for it. Please feel free to verify it by using latest Camel 2.15-SNAPSHOT.
[1]https://issues.apache.org/jira/browse/CAMEL-7966 -- Willem Jiang Red Hat, Inc. Web: http://www.redhat.com Blog: http://willemjiang.blogspot.com (English) http://jnn.iteye.com (Chinese) Twitter: willemjiang Weibo: 姜宁willem On October 23, 2014 at 11:21:50 PM, ychawla ([email protected]) wrote: > Hello All, > The MailBinding class contains this method > setRecipientFromEndpointConfiguration. Perhaps it is just as easy as > checking the recipients map to see if the CC or BCC are blank or empty > string prior to setting them in the method. If so, I wouldn't mind > submitting a patch for this. > > Thanks, > Yogesh > > /** > * Appends the Mail headers from the endpoint configuration. > */ > protected void setRecipientFromEndpointConfiguration(MimeMessage > mimeMessage, MailEndpoint endpoint, Exchange exchange) > throws MessagingException, IOException { > > Map recipients = > endpoint.getConfiguration().getRecipients(); > if (recipients.containsKey(Message.RecipientType.TO)) { > appendRecipientToMimeMessage(mimeMessage, > endpoint.getConfiguration(), exchange, Message.RecipientType.TO.toString(), > recipients.get(Message.RecipientType.TO)); > } > if (recipients.containsKey(Message.RecipientType.CC)) { > appendRecipientToMimeMessage(mimeMessage, > endpoint.getConfiguration(), exchange, Message.RecipientType.CC.toString(), > recipients.get(Message.RecipientType.CC)); > } > if (recipients.containsKey(Message.RecipientType.BCC)) { > appendRecipientToMimeMessage(mimeMessage, > endpoint.getConfiguration(), exchange, Message.RecipientType.BCC.toString(), > recipients.get(Message.RecipientType.BCC)); > } > } > > > > -- > View this message in context: > http://camel.465427.n5.nabble.com/Camel-Mail-CC-and-BCC-headers-tp5757943p5757950.html > > Sent from the Camel - Users mailing list archive at Nabble.com. >
