N°5797 Replace wrong config load (#338)

This commit is contained in:
Pierre Goiffon
2022-12-13 18:23:09 +01:00
committed by GitHub
parent bb26e48d38
commit 1f76ff940d
2 changed files with 6 additions and 7 deletions

View File

@@ -315,7 +315,8 @@ class EMailLaminas extends Email
if ($bForceSynchronous) {
return $this->SendSynchronous($aIssues, $oLog);
} else {
$bConfigASYNC = MetaModel::GetConfig()->Get('email_asynchronous');
$oConfig = $this->LoadConfig();
$bConfigASYNC = $oConfig->Get('email_asynchronous');
if ($bConfigASYNC) {
return $this->SendAsynchronous($aIssues, $oLog);
} else {

View File

@@ -273,13 +273,11 @@ class EmailSwiftMailer extends EMail
}
else
{
$bConfigASYNC = MetaModel::GetConfig()->Get('email_asynchronous');
if ($bConfigASYNC)
{
$oConfig = $this->LoadConfig();
$bConfigASYNC = $oConfig->Get('email_asynchronous');
if ($bConfigASYNC) {
return $this->SendAsynchronous($aIssues, $oLog);
}
else
{
} else {
return $this->SendSynchronous($aIssues, $oLog);
}
}