Allow newlines in invite email and escape other html (#14618)
This commit is contained in:
@@ -607,7 +607,7 @@ public class UsersController : BackOfficeNotificationsController
|
||||
var emailBody = _localizedTextService.Localize("user", "inviteEmailCopyFormat",
|
||||
// Ensure the culture of the found user is used for the email!
|
||||
UmbracoUserExtensions.GetUserCulture(to?.Language, _localizedTextService, _globalSettings),
|
||||
new[] { userDisplay?.Name, from, message, inviteUri.ToString(), senderEmail });
|
||||
new[] { userDisplay?.Name, from, WebUtility.HtmlEncode(message)!.ReplaceLineEndings("<br/>"), inviteUri.ToString(), senderEmail });
|
||||
|
||||
// This needs to be in the correct mailto format including the name, else
|
||||
// the name cannot be captured in the email sending notification.
|
||||
|
||||
Reference in New Issue
Block a user