mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-09-02 22:17:03 +03:00
Added change-smtp-ehlo-message plugin
This commit is contained in:
parent
0422aa5026
commit
57355f2e8a
3 changed files with 46 additions and 0 deletions
25
plugins/change-smtp-ehlo-message/index.php
Normal file
25
plugins/change-smtp-ehlo-message/index.php
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
<?php
|
||||
|
||||
class ChangeSmtpEhloMessagePlugin extends \RainLoop\Plugins\AbstractPlugin
|
||||
{
|
||||
public function Init()
|
||||
{
|
||||
$this->addHook('filter.smtp-credentials', 'FilterSmtpCredentials');
|
||||
}
|
||||
|
||||
/**
|
||||
* @param \RainLoop\Account $oAccount
|
||||
* @param array $aSmtpCredentials
|
||||
*/
|
||||
public function FilterSmtpCredentials($oAccount, &$aSmtpCredentials)
|
||||
{
|
||||
if ($oAccount instanceof \RainLoop\Account && \is_array($aSmtpCredentials))
|
||||
{
|
||||
// Default:
|
||||
// $aSmtpCredentials['Ehlo'] = \MailSo\Smtp\SmtpClient::EhloHelper();
|
||||
//
|
||||
// or write your custom php
|
||||
$aSmtpCredentials['Ehlo'] = 'localhost';
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue