mirror of
https://github.com/egulias/EmailValidator.git
synced 2026-09-01 13:08:58 +00:00
Compare commits
1 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 5642614492 |
@@ -184,7 +184,10 @@ class EmailValidator implements EmailValidatorInterface
|
||||
*/
|
||||
protected function checkDNS()
|
||||
{
|
||||
$mxRecordExists = checkdnsrr(trim($this->parser->getParsedDomainPart()), 'MX');
|
||||
$host = $this->parser->getParsedDomainPart();
|
||||
$host = rtrim($host, '.') . '.';
|
||||
|
||||
$mxRecordExists = checkdnsrr($host, 'MX');
|
||||
|
||||
if (!$mxRecordExists) {
|
||||
$this->warnings[] = self::DNSWARN_NO_RECORD;
|
||||
|
||||
Reference in New Issue
Block a user