It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

How add only comment without old notification via mail handler when I answer html notification?

Hello everybody. When I try to comment issue answering email notification in text format everything is ok , but if I get notification from Jira in html format and answer on it to comment issue, I get a lot of unwanted information such as old notification and From: , Sent:, To:, Subject:  in comment. 

In config StripQuotes is true, but I suppose it works only for text format notifications. What can I do with html format notifications?

Will be glad to any help.

2 answers

1 accepted

I use custom email handler plugin which check StripQuotes parameter in config file and if it's true, then 

NonQuotedCommentHandler nq = new NonQuotedCommentHandler();                    
nq.init(params, messageHandlerErrorCollector);
nq.handleMessage(message, messageHandlerContext);

if StripQuotes = false, then

FullCommentHandler fc = new FullCommentHandler();
fc.init(params, messageHandlerErrorCollector);
fc.handleMessage(message, messageHandlerContext);

As I understand, NonQuotedCommentHandler will strip any quoted lines from the email (ie lines that start with > or |) so text message have old information lines starts with > and that info doesn't add as a comment, but html format message doesn't and so all unwanted information adds as a comment. How can I fix this? May be there some class like NonQuotedCommentHandler where I can tune necessary lines, or I can change html template where I can add ---- Original Message ---- line and then NonQuotedCommentHandler class will not add everything below that line?  

Suggest an answer

Log in or Sign up to answer
TAGS

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you