When logging is set to 'Log everything', it logs a message via Watchdog to say 'Sending mail to: @to'. Unfortunately, it uses the variable "$to", which doesn't exist.
| Comment | File | Size | Author |
|---|---|---|---|
| #12 | smtp-n2651406-9.patch | 1.03 KB | Anonymous (not verified) |
Comments
Comment #2
damienmckennaThis changes it to the correct $message['to'] variable.
Comment #4
damienmckennaThe testbot just says "ERROR: No valid tests were specified.", meaning that it fails because there aren't any tests for the module. That's obviously not the fault of this patch :)
Comment #5
damienmckennaThis should be safe to include in the next release.
Comment #6
Anonymous (not verified) commentedWorks great for me. I tested with one other patch as well. Image of terminal included.
Comment #7
gadaniels72 commentedThis patch work correctly for one of the two instances where an undefined $to is being used. The other is in smtp.mail.inc, line 53. The unpatched instance can be reproduced by checking send email by queue, entering a test email address, have logging set to all, and saving the configuration.
Comment #8
damienmckenna@gadaniels72: Good catch!
This patch covers both bugs.
Comment #9
damienmckennaComment #10
rjbrown99 commentedYour latest patch in #8 needs a change - it's missing a $
FROM:
watchdog('smtp', 'Queue sending mail to: @to', array('@to' => message['to']));
TO:
watchdog('smtp', 'Queue sending mail to: @to', array('@to' => $message['to']));
Comment #11
Anonymous (not verified) commentedI will patch this.
Comment #12
Anonymous (not verified) commentedComment #13
damienmckennaWhoops! Thanks alex_drupal_dev!
Comment #14
gadaniels72 commentedI tested alex_drupal_dev's patch from comment #12 and can confirm that the error messages in both instances have been resolved. Steps to test:
Comment #15
Anonymous (not verified) commentedNo problem. Thanks for the comment. Happy to help patch it. :)
Comment #17
wundo commented