Remove unused $bUsePhpMail

This commit is contained in:
the-djmaze 2023-01-19 10:53:35 +01:00
parent 790edc73c8
commit 890fe132e1

View file

@ -244,9 +244,6 @@ abstract class Account implements \JsonSerializable
$oSettings->Ehlo = \MailSo\Smtp\SmtpClient::EhloHelper(); $oSettings->Ehlo = \MailSo\Smtp\SmtpClient::EhloHelper();
$oPlugins->RunHook('smtp.before-connect', array($this, $oSmtpClient, $oSettings)); $oPlugins->RunHook('smtp.before-connect', array($this, $oSmtpClient, $oSettings));
$bUsePhpMail = $oSettings->usePhpMail;
$oSettings->useAuth = $oSettings->useAuth && !$oSettings->usePhpMail;
if (!$oSettings->usePhpMail) { if (!$oSettings->usePhpMail) {
$oSmtpClient->Connect($oSettings, $oSettings->Ehlo); $oSmtpClient->Connect($oSettings, $oSettings->Ehlo);
} }
@ -256,6 +253,7 @@ abstract class Account implements \JsonSerializable
throw new RequireCredentialsException throw new RequireCredentialsException
} }
*/ */
$oSettings->useAuth = $oSettings->useAuth && !$oSettings->usePhpMail;
$oSettings->Password = $this->sSmtpPassword ?: $this->sPassword; $oSettings->Password = $this->sSmtpPassword ?: $this->sPassword;
return $this->netClientLogin($oSmtpClient, $oPlugins, $oSettings); return $this->netClientLogin($oSmtpClient, $oPlugins, $oSettings);
} }