Fix assigment to static variable for old PHP versions
This commit is contained in:
parent
067ff6e7c0
commit
ecfef2e99c
|
|
@ -842,7 +842,11 @@ class PHPMailer
|
|||
*/
|
||||
public static function fromDSN($dsn, $exceptions = null)
|
||||
{
|
||||
static $configurator = new DSNConfigurator();
|
||||
static $configurator = null;
|
||||
|
||||
if (null === $configurator) {
|
||||
$configurator = new DSNConfigurator();
|
||||
}
|
||||
|
||||
return $configurator->configure(new PHPMailer($exceptions), $dsn);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue