Anope Bug Tracker - Anope Stable (2.0.x series)
View Issue Details
0001632Anope Stable (2.0.x series)[All Projects] Generalpublic2015-02-01 15:522015-03-12 14:16
ptseng 
Adam 
lowtextalways
resolvedfixed 
0001632: Email change confirmation lists old email rather than new.
The default data/example.conf has emailchange_message with "You have requested to change your email address to %e".

Then in SendConfirmMail in modules/commands/ns_set.cpp, we replace %e with the account's current email.

This results in a message being sent to the user claiming "You have requested to change your email address to (OLD EMAIL)", when instead that should be the new email. (The email is, however, correctly sent to the new email)

One possible fix is to replace %e with the new_email var instead. However, some users of Anope may have already assumed %e is the old email and written their emailchange_message accordingly. I think for compatibility it would be wiser to leave %e as is, and introduce a new variable, perhaps named %E, that contains the new email address.

I attached a patch (exported with `git format-patch`, so should be ready to `git am`) to that effect, or open to discussion on the matter. I can submit a PR on github too if that is preferred.
/ns set email newemail@provider.com then check your email.
No tags attached.
patch 0001-SendConfirmMail-Replace-E-with-new-email.patch (2,124) 2015-02-01 15:52
https://bugs.anope.org/file_download.php?file_id=353&type=bug
Issue History
2015-02-01 15:52ptsengNew Issue
2015-02-01 15:52ptsengFile Added: 0001-SendConfirmMail-Replace-E-with-new-email.patch
2015-02-01 16:14ptsengNote Added: 0006694
2015-03-12 14:16AdamNote Added: 0006719
2015-03-12 14:16AdamStatusnew => resolved
2015-03-12 14:16AdamResolutionopen => fixed
2015-03-12 14:16AdamAssigned To => Adam

Notes
(0006719)
Adam   
2015-03-12 14:16   
Applied in bf727285bcf7c7c95c2b2b43faa3d1fa13bad6fb, thanks.
(0006694)
ptseng   
2015-02-01 16:14   
I believe the change in behavior was introduced in 1a3d9a016d3adc49788bbff73aac9b3b5ea85b17