cleanconscience-currency 0.7.0.11 → 0.7.0.13

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/currency.gemspec CHANGED
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = %q{currency}
3
- s.version = "0.7.0.11"
3
+ s.version = "0.7.0.13"
4
4
 
5
5
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
6
6
  s.authors = ["Asa Wilson", "David Palm"]
@@ -70,7 +70,8 @@ class Currency::Exchange::Rate::Source::Xe < ::Currency::Exchange::Rate::Source:
70
70
  raise ParserError, "Currencies header not found" if currency.empty?
71
71
 
72
72
  # Parse out the actual rates, dealing with the explanation gunk about which currency is worth more
73
- parsed_rates = doc.search("table.currency tr:nth-child(0) .c2, table.currency tr:nth-child(0) .cLast").map do |e|
73
+
74
+ parsed_rates = doc.search(".currency tr:nth-child(2) td.c2.cA, .currency tr:nth-child(2) td.cLast").map do |e|
74
75
  if (inner = e.search('div.aboveLayer')).size > 0
75
76
  inner.inner_text.strip
76
77
  else
@@ -90,8 +91,13 @@ class Currency::Exchange::Rate::Source::Xe < ::Currency::Exchange::Rate::Source:
90
91
  $stderr.puts "#{cur.inspect} => #{usd_to_cur}" if @verbose
91
92
  end
92
93
 
94
+
95
+
96
+
93
97
  raise ::Currency::Exception::UnavailableRates, "No rates found in #{get_uri.inspect}" if rate.keys.empty?
94
98
 
99
+
100
+
95
101
  raise ParserError,
96
102
  [
97
103
  "Not all currencies found",
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cleanconscience-currency
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.7.0.11
4
+ version: 0.7.0.13
5
5
  platform: ruby
6
6
  authors:
7
7
  - Asa Wilson
@@ -10,7 +10,7 @@ autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
12
 
13
- date: 2009-03-20 09:47:42.765449 -07:00
13
+ date: 2009-03-23 15:07:28.103443 -07:00
14
14
  default_executable:
15
15
  dependencies: []
16
16