aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Vitaly Takmazov2017-12-27 11:43:50 +0300
committerGravatar Vitaly Takmazov2017-12-27 11:43:50 +0300
commitae30ec865373868228eac7ff4a04f9a732c6346d (patch)
tree4bd5b947c5349f048433acdd7885e23976fb7d15
parent8e157c7861d1b5e3a1687c9ff4ff570e00a1396d (diff)
email: brackets in message id
-rw-r--r--juick-api/src/main/java/com/juick/api/EmailManager.java6
1 files changed, 3 insertions, 3 deletions
diff --git a/juick-api/src/main/java/com/juick/api/EmailManager.java b/juick-api/src/main/java/com/juick/api/EmailManager.java
index 2287d063..df15d9de 100644
--- a/juick-api/src/main/java/com/juick/api/EmailManager.java
+++ b/juick-api/src/main/java/com/juick/api/EmailManager.java
@@ -62,14 +62,14 @@ public class EmailManager implements ApplicationListener<MessageEvent> {
Transport transport = session.getTransport("smtp");
MimeMessage message = new MimeMessage(session) {
protected void updateMessageID() throws MessagingException {
- setHeader("Message-ID", String.format("%d.%d@juick.com", msg.getMid(), msg.getRid()));
+ setHeader("Message-ID", String.format("<%d.%d@juick.com>", msg.getMid(), msg.getRid()));
if (msg.getRid() > 0) {
if (msg.getReplyto() > 0) {
Message replyto = messagesService.getReply(msg.getMid(), msg.getReplyto());
- setHeader("In-Reply-To", String.format("%d.%d@juick.com", replyto.getMid(), replyto.getRid()));
+ setHeader("In-Reply-To", String.format("<%d.%d@juick.com>", replyto.getMid(), replyto.getRid()));
} else {
Message original = messagesService.getMessage(msg.getMid());
- setHeader("In-Reply-To", String.format("%d.%d@juick.com", original.getMid(), original.getRid()));
+ setHeader("In-Reply-To", String.format("<%d.%d@juick.com>", original.getMid(), original.getRid()));
}
}
}