Commit 328fc57f authored by michael.simon's avatar michael.simon
Browse files

Also null check for body and subject in mail templates

parent 8abf5de8
......@@ -73,8 +73,12 @@ public class MailServiceImpl implements MailService {
message.setRecipients(Message.RecipientType.BCC,
InternetAddress.parse(bcc, false));
message.setSubject(subject);
message.setText(body);
if (subject != null)
message.setSubject(subject);
if (body != null)
message.setText(body);
message.setHeader("X-Mailer", "bwIdm Webregistrierung Mail");
message.setSentDate(new Date());
Transport.send(message);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment