<commit_before><?php

class Doctrine_Validator_Email {

    /**
     * @link http://iamcal.com/publish/articles/php/parsing_email/pdf/
     * @param Doctrine_Record $record
     * @param string $key
     * @param mixed $value
     * @param string $args
     * @return boolean
     */
    public function validate(Doctrine_Record $record, $key, $value, $args) {
        if(empty($value)) 
            return true;

        $parts = explode("@", $value);
        if(isset($parts[1]) && function_exists("checkdnsrr")) {
            if( ! checkdnsrr($parts[1], "MX"))
                return false;
        }
<commit_msg>MX checking disabled by default<commit_after><?php

class Doctrine_Validator_Email {

    /**
     * @link http://iamcal.com/publish/articles/php/parsing_email/pdf/
     * @param Doctrine_Record $record
     * @param string $key
     * @param mixed $value
     * @param string $args
     * @return boolean
     */
    public function validate(Doctrine_Record $record, $key, $value, $args) {
        if(empty($value)) 
            return true;

        if(isset($args[0])) {
            $parts = explode("@", $value);
            if(isset($parts[1]) && function_exists("checkdnsrr")) {
                if( ! checkdnsrr($parts[1], "MX"))
                    return false;
            }
        }

{'fraction_non_alphanumeric': 0.14427480916030536, 'fraction_numerical': 0.003816793893129771, 'mean_word_length': 2.1820388349514563, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3716246', 'n_tokens_mistral': 402, 'n_tokens_neox': 392, 'n_words': 83}