Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

support 'domain' and 'registrar' properties on whois.dns.be.rb #213

Closed
wants to merge 1 commit into from

2 participants

@chuckadams

What the title says: this patch adds support for those two properties for .be

@chuckadams

Sorry for the formatting, looks like some leading tabs snuck into the example. Won't be too offended if you reject and copy/paste the changes instead :)

@weppos
Owner

@chuckadams thanks for the contribution. Unfortunately, I cannot merge it becase, alignment aparts, the changes are missing the corresponding tests.

Please submit the tests if you want the patch to be accepted.

@weppos weppos closed this
@weppos weppos was assigned
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Mar 27, 2013
This page is out of date. Refresh to see the latest.
Showing with 17 additions and 0 deletions.
  1. +17 −0 lib/whois/record/parser/whois.dns.be.rb
View
17 lib/whois/record/parser/whois.dns.be.rb
@@ -76,6 +76,23 @@ class WhoisDnsBe < Base
end
+ # EXAMPLE: nic.be
+ # Domain: nic.be
+ property_supported :domain do
+ content_for_scanner.slice(/Domain:\s*(.+?)\n/, 1)
+ end
+
+ # EXAMPLE: nic.be
+ # Registrar:
+ # Name: Telenet NV
+ # Website: www.hostbasket.com
+ property_supported :registrar do
+ name = content_for_scanner.slice(/Registrar:\s+Name:(.+?)\s*Website:(.+?)\n/, 1)
+ url = content_for_scanner.slice(/Registrar:\s+Name:(.+?)\s*Website:(.+?)\n/, 2)
+ name and url and Record::Registrar.new(:name => name.strip, :url => url.strip)
+ end
+
+
# Checks whether the response has been throttled.
#
# @return [Boolean]
Something went wrong with that request. Please try again.