summaryrefslogtreecommitdiff
path: root/modules/commands/ns_set.cpp
diff options
context:
space:
mode:
authorPeter Tseng <pht24@cornell.edu>2015-02-01 13:43:42 +0000
committerAdam <Adam@anope.org>2015-03-11 14:44:38 -0400
commitbf727285bcf7c7c95c2b2b43faa3d1fa13bad6fb (patch)
tree9c036c5646989fe436fce4d4e7d651e722b203c0 /modules/commands/ns_set.cpp
parent310e95a92e64a9546247fe57d4643328fa4ebe9b (diff)
SendConfirmMail: Replace %E with new email
The old mailer message said the user is changing email "to %e", which is changing TO the OLD email. But instead, the user is actually changing the email to the new email. We could change %e to be the new email, but maybe some users of Anope have already configured their messages to assume %e is the old email. So instead, add a new %E that is replaced with the new email.
Diffstat (limited to 'modules/commands/ns_set.cpp')
-rw-r--r--modules/commands/ns_set.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/modules/commands/ns_set.cpp b/modules/commands/ns_set.cpp
index 03ebae85c..fdf2a5e38 100644
--- a/modules/commands/ns_set.cpp
+++ b/modules/commands/ns_set.cpp
@@ -414,10 +414,12 @@ class CommandNSSetEmail : public Command
message = Config->GetBlock("mail")->Get<const Anope::string>("emailchange_message");
subject = subject.replace_all_cs("%e", u->Account()->email);
+ subject = subject.replace_all_cs("%E", new_email);
subject = subject.replace_all_cs("%N", Config->GetBlock("networkinfo")->Get<const Anope::string>("networkname"));
subject = subject.replace_all_cs("%c", code);
message = message.replace_all_cs("%e", u->Account()->email);
+ message = message.replace_all_cs("%E", new_email);
message = message.replace_all_cs("%N", Config->GetBlock("networkinfo")->Get<const Anope::string>("networkname"));
message = message.replace_all_cs("%c", code);