This commit is contained in:
Paula Quispe
2018-04-17 14:52:21 -04:00
parent 1c2c7d69cd
commit 6c215b9d22
2 changed files with 34 additions and 8 deletions

View File

@@ -1395,5 +1395,27 @@ class EmailServer
throw $e;
}
}
/**
* Define the value for MESS_LABEL
*
* @param string $engine, can be PHPMAILER|MAIL
* @param string $senderAccount, related to the MESS_ACCOUNT
* @param string $senderEmail, related to the MESS_FROM_MAIL
*
* @return string
*/
public static function getMessLabel($engine = 'PHPMAILER', $senderAccount = '', $senderEmail = '')
{
$messLabel = $senderEmail;
if (empty($senderAccount) && $engine === 'MAIL') {
$senderAccount = 'Mail (PHP)';
}
if (empty($senderEmail)) {
$messLabel = $senderAccount;
}
return $messLabel;
}
}