Problem/Motivation
The backward compatibility MailManagerReplacement::mail() function always sends emails, even if the $send variable is set to FALSE. It should only send when $send = TRUE.
Steps to reproduce
I'm seeing this in Easy Email module. If you use the Easy Email Overrides sub-module, you can create a replacement email for the password recovery email. When used with Swift Mailer, the override works correctly, but with Symfony Mailer both emails are sent.
Proposed resolution
Patch attached.
Remaining tasks
Review patch.
User interface changes
None.
API changes
I think there should be none, however perhaps there is other code relying on the current behavior of this function.
Data model changes
None.
Comments
Comment #2
zengenuity commentedComment #3
adamps commentedGood idea thanks.
We should probably also return the correct value of 'send'
Comment #4
zengenuity commentedThis patch also updates the return value.
Comment #6
adamps commentedThanks