Permalink
Browse files

Merge pull request #11 from DTrierweiler/master

Metric Values should be float in order to handle percentage values
  • Loading branch information...
2 parents 09dd828 + 7362a40 commit 9669ab601689a2c67b48128e0938703cead9bfd9 Chris Le committed May 10, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/gattica/data_point.rb
@@ -20,7 +20,7 @@ def initialize(xml)
{ dimension.attributes['name'].split(':').last.to_sym => dimension.attributes['value'].split(':').last }
end
@metrics = xml.search('dxp:metric').collect do |metric|
- { metric.attributes['name'].split(':').last.to_sym => metric.attributes['value'].split(':').last.to_i }
+ { metric.attributes['name'].split(':').last.to_sym => metric.attributes['value'].split(':').last.to_f }
end
end

0 comments on commit 9669ab6

Please sign in to comment.