hansef-checkdomain 1.0.7 → 1.0.8

Sign up to get free protection for your applications and to get access to all the features.
@@ -8,7 +8,7 @@ require 'checkdomain/search'
8
8
  require 'checkdomain/domain'
9
9
 
10
10
  module CheckDomain
11
- VERSION = '1.0.0'
11
+ VERSION = '1.0.8'
12
12
 
13
13
  TLDS = %W(
14
14
  aero asia biz cat com coop edu gov info int jobs mil mobi museum name net org
@@ -24,6 +24,8 @@ module CheckDomain
24
24
  end
25
25
  end
26
26
 
27
+ private
28
+
27
29
  def nx_domain?
28
30
  answer = resolver.search(self.name)
29
31
  answer.header.rCode.type == "NXDomain"
@@ -38,14 +40,7 @@ module CheckDomain
38
40
  end
39
41
 
40
42
  def whois_match?
41
- whois = `whois #{self.name}`
42
- if whois.match("(No match for|NOT FOUND)")
43
- false
44
- elsif whois.match("LAMEDELEGATION")
45
- true
46
- else
47
- true
48
- end
43
+ !`whois #{self.name}`.match("(No match for|NOT FOUND)")
49
44
  end
50
45
 
51
46
  def is_taken
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: hansef-checkdomain
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.7
4
+ version: 1.0.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Hans Friedrich