Sha256: 3aad9dab82adaa6cf863ab3008451a4cb75961151da22b51275251573c549650
Contents?: true
Size: 253 Bytes
Versions: 2
Compression:
Stored size: 253 Bytes
Contents
require "resolv" module DomainValidator class DnsCheck def self.has_record?(domain) begin Resolv::DNS.new.getaddress domain return true rescue Resolv::ResolvError => e return false end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
domain_validator-0.1.1 | lib/domain_validator/dns_check.rb |
domain_validator-0.1.0 | lib/domain_validator/dns_check.rb |