Skip to content

Commit

Permalink
fix broken threading issue
Browse files Browse the repository at this point in the history
  • Loading branch information
martgil committed Nov 28, 2024
1 parent e740933 commit 5c843f7
Showing 1 changed file with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -98,9 +98,11 @@ export class ComposeRenderModule extends ViewModule<ComposeView> {
const thread = await this.view.emailProvider.threadGet(this.view.threadId, 'metadata');
const inReplyToMessage = thread.messages?.find(message => message.id === this.view.replyMsgId);
if (inReplyToMessage) {
this.view.replyParams.inReplyTo = inReplyToMessage.payload?.headers?.find(
header => header.name === 'Message-Id' || header.name === 'Message-ID'
)?.value;
const msgId = inReplyToMessage.payload?.headers?.find(header => header.name === 'Message-Id' || header.name === 'Message-ID')?.value;
if (msgId) {
this.view.sendBtnModule.additionalMsgHeaders['In-Reply-To'] = msgId;
this.view.sendBtnModule.additionalMsgHeaders.References = msgId;
}
}
this.view.replyParams.subject = `${this.responseMethod === 'reply' ? 'Re' : 'Fwd'}: ${this.view.replyParams.subject}`;
if (this.view.useFullScreenSecureCompose) {
Expand Down

0 comments on commit 5c843f7

Please sign in to comment.