cryptocoincharts_ruby 0.0.16 → 0.0.17

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +8 -8
  2. data/lib/cryptocoincharts_ruby.rb +11 -11
  3. metadata +1 -1
checksums.yaml CHANGED
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- ZmE0Yzg5M2ViMGI3MWVlOWIyYTNlZTU3YTllY2I1MTZkZmQxMGYyNw==
4
+ NDBjNjVmNGY2YmM5YzViYTc0ZDU2YzVhZGMxZDcxYmViZDgyODJiMw==
5
5
  data.tar.gz: !binary |-
6
- MWI3NGVjNzhkOGE0ZGM3MTNhY2IwZjUzNDg2YjEyOWU3ODdhNDY3OQ==
6
+ OWYyNjQwZDU5N2NmMjg1NTNlM2YzZjFhM2M2OThlYjc0N2FlOTQxMQ==
7
7
  SHA512:
8
8
  metadata.gz: !binary |-
9
- NmYzMTAzYmI3MDU0NTMzNGM2ZGRhN2E3NjY1NTM4MjI1MWRjZTBiNzRkYmY2
10
- MTAwZWQxMDEwNzIxYjJkYjVlNzMyMDMxMTRjNGVkMzJiMjFhOTdiM2ZiMTQz
11
- MTliMDNhMjAzODdhNTU5N2Y0NWM5YmU5MzhlNjU0MjliYzNhMmE=
9
+ MDlmMDgzYzg2NDdlZWJmNDM1NDY1NzA5NmRjNDkwY2I3NDlmNjMwNmZiZTgw
10
+ M2JhZWNlOGJkOTU1ZThhODFhMThhODdmNzExNDEwODkxMzhmZTJjMWQxNWFl
11
+ Nzc4YTNjY2EyNzlhODFmMGMxODliODA5OWNhZGUzOGM3MTZjZWY=
12
12
  data.tar.gz: !binary |-
13
- YzFiNjdlNTg4MjExNjI2ZTE3YWI1MjFmNzFmN2JkNjc2ZDMwNTEyZmVmMDlk
14
- ODllMDk1YTRhYTg5ZDVhYWJlZjk1NTA4YThmOTRjNzQxODg2MDI0NmRjMTQ4
15
- MTRlNWVlMjBiNmQ4ZTdmOTBhMDVjNDY5NWVhYjdjNDJhMDQ1Zjk=
13
+ MWU0YTlmNzkyYWE4NjNmMzBkOTY0NzgzMjU5OTMxMGQ1YzEzYTg1NDc4YjQ3
14
+ MTlhZGYxYWIxZGVkODg2N2Q4NzE2OWFmZThmMTQ5NDRhNjVjMGU1MWUxOGE1
15
+ YTk2ZTg4YTJmODhjYjBhNjJlNTlkODlhMWJlMTdjNjA4N2FhZDY=
@@ -6,7 +6,7 @@ require 'bigdecimal'
6
6
  module CryptoCoinCharts
7
7
  class << self
8
8
 
9
- VERSION = '0.0.16'
9
+ VERSION = '0.0.17'
10
10
 
11
11
  API_URL = 'http://www.cryptocoincharts.info/v2/api'
12
12
  VALID_PAIRS = [
@@ -80,21 +80,21 @@ module CryptoCoinCharts
80
80
  end
81
81
 
82
82
  class CoinSummary < Hashie::Trash
83
- property :id, :transform_with => lambda {|v| v.to_sym }
83
+ property :id, :transform_with => lambda {|v| v.to_s.to_sym }
84
84
  property :name
85
85
  property :website
86
- property :price_btc, :transform_with => lambda {|v| BigDecimal.new(v) }
87
- property :volume_btc, :transform_with => lambda {|v| v.to_f }
86
+ property :price_btc, :transform_with => lambda {|v| BigDecimal.new(v.to_s) }
87
+ property :volume_btc, :transform_with => lambda {|v| v.to_s.to_f }
88
88
  end
89
89
 
90
90
  class CoinDetail < Hashie::Trash
91
- property :id, :transform_with => lambda {|v| v.gsub!(/\//, '_').to_sym }
91
+ property :id, :transform_with => lambda {|v| v.to_s.gsub!(/\//, '_').to_sym }
92
92
  property :best_market
93
- property :latest_trade, :transform_with => lambda {|v| Time.parse(v) rescue v }
94
- property :price, :transform_with => lambda {|v| BigDecimal.new(v) }
95
- property :price_before_24h, :transform_with => lambda {|v| BigDecimal.new(v) }
96
- property :volume_btc, :transform_with => lambda {|v| v.to_f }
97
- property :volume_first, :transform_with => lambda {|v| v.to_f }
98
- property :volume_second, :transform_with => lambda {|v| v.to_f }
93
+ property :latest_trade, :transform_with => lambda {|v| Time.parse(v.to_s) rescue v }
94
+ property :price, :transform_with => lambda {|v| BigDecimal.new(v.to_s) }
95
+ property :price_before_24h, :transform_with => lambda {|v| BigDecimal.new(v.to_s) }
96
+ property :volume_btc, :transform_with => lambda {|v| v.to_s.to_f }
97
+ property :volume_first, :transform_with => lambda {|v| v.to_s.to_f }
98
+ property :volume_second, :transform_with => lambda {|v| v.to_s.to_f }
99
99
  end
100
100
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cryptocoincharts_ruby
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.16
4
+ version: 0.0.17
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ethan Barron