Merge pull request #683 from drewcsillag/dovecot-master-user

Break username and domain from login on last @ instead of first @
This commit is contained in:
RainLoop Team 2015-05-21 22:58:06 +03:00
commit e39249d4d7

View file

@ -872,7 +872,7 @@ END;
$sResult = '';
if (0 < \strlen($sEmail))
{
$iPos = \strpos($sEmail, '@');
$iPos = \strrpos($sEmail, '@');
$sResult = (false === $iPos) ? $sEmail : \substr($sEmail, 0, $iPos);
}
@ -889,7 +889,7 @@ END;
$sResult = '';
if (0 < \strlen($sEmail))
{
$iPos = \strpos($sEmail, '@');
$iPos = \strrpos($sEmail, '@');
if (false !== $iPos && 0 < $iPos)
{
$sResult = \substr($sEmail, $iPos + 1);