mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-10-15 19:54:57 +08:00
Adding messageprepared flag to user registration email event handler to allow handler swaping.
--HG-- branch : dev
This commit is contained in:
@@ -20,6 +20,9 @@ namespace Orchard.Users.Handlers {
|
||||
public Localizer T { get; set; }
|
||||
|
||||
public void Sending(MessageContext context) {
|
||||
if (context.MessagePrepared)
|
||||
return;
|
||||
|
||||
var contentItem = _contentManager.Get(context.Recipient.Id);
|
||||
if ( contentItem == null )
|
||||
return;
|
||||
@@ -51,6 +54,7 @@ namespace Orchard.Users.Handlers {
|
||||
}
|
||||
|
||||
FormatEmailBody(context);
|
||||
context.MessagePrepared = true;
|
||||
}
|
||||
|
||||
private static void FormatEmailBody(MessageContext context) {
|
||||
|
Reference in New Issue
Block a user