lib/classes/Swift/Transport/Esmtp/Auth/NTLMAuthenticator.php
protected function getDomainAndUsername($name)
    {
        if (false !== strpos($name, '\\')) {
            return explode('\\', $name);
        }

        if (false !== strpos($name, '@')) {
            list($user, $domain) = explode('@', $name);

            return [$domain, $user];
        }

        // no domain passed
        return ['', $name];
    }
protected function getDomainAndUsername($name)
    {
        if (false !== strpos($name, '\\')) {
            return explode('\\', $name);
        }

        if (false !== strpos($name, '@')) {
            list($user, $domain) = explode('@', $name);

            return [$domain, $user];
        }

        // no domain passed
        return ['', $name];
    }
protected function getDomainAndUsername ( $ name ) { if ( false !== strpos ( $ name , '\\' ) ) { return explode ( '\\' , $ name ) ; } if ( false !== strpos ( $ name , '@' ) ) { list ( $ user , $ domain ) = explode ( '@' , $ name ) ; return [ $ domain , $ user ] ; } // no domain passed return [ '' , $ name ] ; }
Get domain and username from our username.

@example DOMAIN\username

@param string $name

@return array
Get domain and username from our username .