name_dot_com_api 0.3 → 0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/lib/name_dot_com_api/client.rb +4 -1
- data/lib/name_dot_com_api/version.rb +1 -1
- metadata +3 -3
@@ -132,13 +132,16 @@ module NameDotComApi
|
|
132
132
|
# }
|
133
133
|
# ])
|
134
134
|
def create_domain(domain, period = 1, nameservers = nil, contacts = nil)
|
135
|
-
|
135
|
+
options = {
|
136
136
|
'domain_name' => domain,
|
137
137
|
'period' => period,
|
138
138
|
'nameservers' => nameservers,
|
139
139
|
'contacts' => contacts,
|
140
140
|
'username' => connection.username
|
141
141
|
}
|
142
|
+
options.delete('nameservers') unless nameservers
|
143
|
+
options.delete('contacts') unless contacts
|
144
|
+
connection.post '/domain/create', options
|
142
145
|
end
|
143
146
|
|
144
147
|
# response = client.get_domain('example.com')
|
metadata
CHANGED
@@ -4,8 +4,8 @@ version: !ruby/object:Gem::Version
|
|
4
4
|
prerelease: false
|
5
5
|
segments:
|
6
6
|
- 0
|
7
|
-
-
|
8
|
-
version: "0.
|
7
|
+
- 4
|
8
|
+
version: "0.4"
|
9
9
|
platform: ruby
|
10
10
|
authors:
|
11
11
|
- Nicholas Barthelemy
|
@@ -13,7 +13,7 @@ autorequire:
|
|
13
13
|
bindir: bin
|
14
14
|
cert_chain: []
|
15
15
|
|
16
|
-
date: 2011-12-
|
16
|
+
date: 2011-12-15 00:00:00 -06:00
|
17
17
|
default_executable:
|
18
18
|
dependencies:
|
19
19
|
- !ruby/object:Gem::Dependency
|