aboutsummaryrefslogtreecommitdiff
path: root/src/org/traccar/notification/NotificationMail.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/org/traccar/notification/NotificationMail.java')
-rw-r--r--src/org/traccar/notification/NotificationMail.java5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/org/traccar/notification/NotificationMail.java b/src/org/traccar/notification/NotificationMail.java
index 90f6bd75e..7b7ef6e74 100644
--- a/src/org/traccar/notification/NotificationMail.java
+++ b/src/org/traccar/notification/NotificationMail.java
@@ -106,8 +106,9 @@ public final class NotificationMail {
}
message.addRecipient(Message.RecipientType.TO, new InternetAddress(user.getEmail()));
- message.setSubject(NotificationFormatter.formatTitle(userId, event, position));
- message.setText(NotificationFormatter.formatMessage(userId, event, position));
+ MailMessage mailMessage = NotificationFormatter.formatMessage(userId, event, position);
+ message.setSubject(mailMessage.getSubject());
+ message.setContent(mailMessage.getBody(), "text/html; charset=utf-8");
Transport transport = session.getTransport();
try {