Closed (fixed)
Project:
SMTP Authentication Support
Version:
7.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
9 Oct 2012 at 11:17 UTC
Updated:
19 Feb 2020 at 17:36 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
tobiasbThe patch does the same like it does in a newer version of phpmailer https://github.com/Synchro/PHPMailer/blob/master/class.phpmailer.php#L1643
Comment #2
tobiasbOk now it does the same ;-)
Comment #3
josesanmartin commentedTested and commited to master!
Thanks tobiasb!
Comment #5
u_tiwari commentedHi , phpcs still register this error and might possibly lead to undefined function errors in some php versions.
Is there any permanent fix for this or can this be addressed.
Comment #6
lisa.rae commented@u_tiwari -- PHPCS is a static code scanner. If you look at the logic in the patch, you'll see that the code block that is causing PHPCS to flag this as a coding error has logic to skip the block if the version of PHP running the site is greater than version 6, which means that these lines of code will be bypassed if you are running PHP version 7+.
With that said, Drupal is no longer supporting PHP version 5, so theoretically this can be removed; however I am also aware that there are sites still running on PHP 5.6 so the current logic should handle any execution issues on PHP 7+