Early Bird Registration for DrupalCon Portland 2024 is open! Register by 23:59 PST on 31 March 2024, to get $100 off your ticket.
When the PHPMailer class is instantiated, it is done so without any arguments.
Which leads to PHPMailer echoing all errors. This will in turn break a batch process where the error corrupts the json the batch is expecting to see.
Comment | File | Size | Author |
---|---|---|---|
#12 | interdiff_9-10.txt | 2.41 KB | tapaswini sahoo |
#10 | smtp-n2358001-10.patch | 1.52 KB | bkosborne |
| |||
#9 | smtp-n2358001-9.patch | 1.54 KB | DamienMcKenna |
|
Comments
Comment #1
thomasth CreditAttribution: thomasth commentedComment #2
rossb89 CreditAttribution: rossb89 at ComputerMinds commentedI just ran into this issue myself, and took a while to work out that the 'true' parameter is required to get the exceptions to be thrown so we can catch them.
Guess this isn't an issue many people run into, but it certainly affected me.
Comment #3
DamienMcKennaDon't forget to set the issue status to "needs review" when you add a patch.
Comment #5
DamienMcKennaHow about making it optional?
Comment #6
Anonymous (not verified) CreditAttribution: Anonymous as a volunteer and commentedLooks good to me.
Comment #7
rossb89 CreditAttribution: rossb89 at ComputerMinds commentedHaven't tested this new version of the patch, but I agree, probably makes more sense to have this optional :)
Comment #8
DamienMcKenna@wundo: I think this one should be safe to include in 1.4.
Comment #9
DamienMcKennaRerolled, because of the new variable in hook_uninstall.
Comment #10
bkosborneRe-rolled.
However, I don't think this is valid anymore. I looked at the few places that PHPMailer actually uses this variable to handle exceptions/logging, and in no cases is it just "echoing" the error. It will either throw an exception or it will call Drupal's watchdog function. Perhaps when this issue was created 2 years ago, the version of PHPMailer that was used with the module was different?
Comment #11
tapaswini sahoo CreditAttribution: tapaswini sahoo at Valuebound for Valuebound commentedComment #12
tapaswini sahoo CreditAttribution: tapaswini sahoo at Valuebound for Valuebound commentedi applied interdiff on this two patch.