2 3 4
# File 'lib/brazilian-documents-validations/cnpj_validator.rb', line 2 def validate_each(record, attribute, value) record.errors.add(attribute, options[:message]) if CNPJ.invalid?(value) end