Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ENH: Use message subject when sending instant subscription messages #6199

Open
wants to merge 3 commits into
base: develop
Choose a base branch
from
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Licensed to the .NET Foundation under one or more agreements.
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information

Expand Down Expand Up @@ -695,7 +695,6 @@ private void SendMessage(MessageRecipient messageRecipient)
var defaultLanguage = toUser.Profile.PreferredLocale;
var portalSettings = new PortalSettings(message.PortalID);

var emailSubjectTemplate = GetEmailSubjectTemplate(portalSettings, defaultLanguage);
var emailBodyTemplate = GetEmailBodyTemplate(portalSettings, defaultLanguage);
var emailBodyItemTemplate = GetEmailBodyItemTemplate(portalSettings, defaultLanguage);

Expand All @@ -708,8 +707,8 @@ private void SendMessage(MessageRecipient messageRecipient)
{
var senderName = GetSenderName(author.DisplayName, portalSettings.PortalName);
var senderAddress = GetSenderAddress(senderName, portalSettings.Email);
var emailBodyItemContent = GetEmailItemContent(portalSettings, messageRecipient, emailBodyItemTemplate);
var subject = string.Format(emailSubjectTemplate, portalSettings.PortalName);
var emailBodyItemContent = GetEmailItemContent(portalSettings, messageRecipient, emailBodyItemTemplate);
var subject = InternalMessagingController.Instance.GetMessage(message.MessageID).Subject;
johnhenley marked this conversation as resolved.
Show resolved Hide resolved
var body = GetEmailBody(emailBodyTemplate, emailBodyItemContent, portalSettings, toUser);
body = RemoveHttpUrlsIfSiteisSSLEnabled(body, portalSettings);

Expand Down