nominet-epp 0.0.11 → 0.0.12

Sign up to get free protection for your applications and to get access to all the features.
data/History.rdoc CHANGED
@@ -1,5 +1,9 @@
1
1
  = NominetEPP History
2
2
 
3
+ === 0.0.12 / 2011-05-24
4
+
5
+ * Capture +domain:failData+ information from +create+ operation failures.
6
+
3
7
  === 0.0.11 / 2011-05-17
4
8
 
5
9
  * Remove setting account:contact[type] attribute as this is not in the schema
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.0.11
1
+ 0.0.12
data/lib/nominet-epp.rb CHANGED
@@ -43,6 +43,15 @@ module NominetEPP
43
43
  last_response.message
44
44
  end
45
45
 
46
+ # Returns the last Nominet failData response found
47
+ #
48
+ # @note This is presently only set by certain method calls,
49
+ # so it may not always be present.
50
+ # @return [Hash] last failData found
51
+ def last_error_info
52
+ @error_info
53
+ end
54
+
46
55
  # @return [Hash] Nominet Namespaces by prefixes
47
56
  def namespaces
48
57
  { :domain => 'http://www.nominet.org.uk/epp/xml/nom-domain-2.0',
@@ -65,7 +65,12 @@ module NominetEPP
65
65
  end
66
66
  end
67
67
 
68
- return false unless @resp.success?
68
+ unless @resp.success?
69
+ @error_info = {
70
+ :name => node_value(@resp.data, '//domain:failData/domain:name/node()'),
71
+ :reason => node_value(@resp.data, '//domain:failData/domain:reason/node()') }
72
+ return false
73
+ end
69
74
 
70
75
  creData = @resp.data.find('//domain:creData', namespaces).first
71
76
  h = { :name => node_value(creData, 'domain:name'),
data/nominet-epp.gemspec CHANGED
@@ -5,11 +5,11 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{nominet-epp}
8
- s.version = "0.0.11"
8
+ s.version = "0.0.12"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Geoff Garside"]
12
- s.date = %q{2011-05-17}
12
+ s.date = %q{2011-05-24}
13
13
  s.description = %q{Client for communicating with the Nominet EPP}
14
14
  s.email = %q{geoff@geoffgarside.co.uk}
15
15
  s.extra_rdoc_files = [
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: nominet-epp
3
3
  version: !ruby/object:Gem::Version
4
- hash: 9
4
+ hash: 7
5
5
  prerelease:
6
6
  segments:
7
7
  - 0
8
8
  - 0
9
- - 11
10
- version: 0.0.11
9
+ - 12
10
+ version: 0.0.12
11
11
  platform: ruby
12
12
  authors:
13
13
  - Geoff Garside
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2011-05-17 00:00:00 Z
18
+ date: 2011-05-24 00:00:00 Z
19
19
  dependencies:
20
20
  - !ruby/object:Gem::Dependency
21
21
  name: shoulda