money-coinmarketcap-bank 0.1.3 → 0.1.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ee21fe1a7437cdd09b1c5d329b54e59b9e6c3158
4
- data.tar.gz: 3941adddb496555702b63ccd6276d5188e59e902
3
+ metadata.gz: 99e15350374b01622deda04e9878bf8aa164a533
4
+ data.tar.gz: 5a9c981919f0eb7312b8abf3f4db5b71f86e5f47
5
5
  SHA512:
6
- metadata.gz: 48dd8bcd993544bb4074dc7afefdefa9af74bb57cd8debb9fbde5494a81eab60374dea2bec1286ffb647a548df699a0c54aa6335dae1b3aa1ee07d6bd1c7eccd
7
- data.tar.gz: 21b90d74f9206e619c746323e4238df86c2e783334ec6ffa4b347f1732821c1cb8bd13af71a6e44836ea5ba86b92bfbec449f786d8ed225c9074f0973a3b1e71
6
+ metadata.gz: 8e96f369324eec7b1c5c8d27ef552a708ec129381bf1e83218ff778b8e5e164d3e3420a791d80894f8592b9a4ba74025de71bc9d427020d0c6593c40e5a45a34
7
+ data.tar.gz: 3dd0456f5311dbcce38b2b9ae0c220db23021b88dbd90d40f3378e61b91497a8a1a5b48ae58ce5594611c8d8f6f8f5811ecad6f5b67cf47b553f5d3d85182bc2
@@ -12,6 +12,9 @@ class Money
12
12
  # Seconds after which the current rates are automatically expired
13
13
  attr_accessor :ttl_in_seconds
14
14
 
15
+ # List of currencies
16
+ attr_reader :currencies
17
+
15
18
  # Rates expiration time
16
19
  attr_reader :rates_expire_at
17
20
 
@@ -26,6 +29,8 @@ class Money
26
29
  add_rate(iso_from, iso_to, nil)
27
30
  end
28
31
 
32
+ self.currencies = []
33
+
29
34
  add_exchange_rates
30
35
  end
31
36
 
@@ -67,6 +72,8 @@ class Money
67
72
  next if currency['availableSupplyNumber'] == 0
68
73
 
69
74
  iso_from = currency['symbol']
75
+ self.currencies << iso_from
76
+
70
77
  currency['price'].each do |iso_to, rate|
71
78
  iso_to = iso_to.upcase
72
79
  next unless Money::Currency.find(iso_from) && Money::Currency.find(iso_to)
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new { |s|
2
2
  s.name = 'money-coinmarketcap-bank'
3
- s.version = '0.1.3'
3
+ s.version = '0.1.4'
4
4
  s.author = 'Giovanni Capuano'
5
5
  s.email = 'webmaster@giovannicapuano.net'
6
6
  s.homepage = 'https://github.com/RoxasShadow'
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: money-coinmarketcap-bank
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.3
4
+ version: 0.1.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Giovanni Capuano
@@ -14,28 +14,28 @@ dependencies:
14
14
  name: money
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - ~>
17
+ - - "~>"
18
18
  - !ruby/object:Gem::Version
19
19
  version: '6.9'
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - ~>
24
+ - - "~>"
25
25
  - !ruby/object:Gem::Version
26
26
  version: '6.9'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: rake
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - ~>
31
+ - - "~>"
32
32
  - !ruby/object:Gem::Version
33
33
  version: '12.0'
34
34
  type: :development
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
- - - ~>
38
+ - - "~>"
39
39
  - !ruby/object:Gem::Version
40
40
  version: '12.0'
41
41
  description: Attach this gem to ruby-money to use it as bank and get the exchange
@@ -45,7 +45,7 @@ executables: []
45
45
  extensions: []
46
46
  extra_rdoc_files: []
47
47
  files:
48
- - .gitignore
48
+ - ".gitignore"
49
49
  - README.md
50
50
  - Rakefile
51
51
  - lib/money/bank/coin_market_cap.rb
@@ -60,17 +60,17 @@ require_paths:
60
60
  - lib
61
61
  required_ruby_version: !ruby/object:Gem::Requirement
62
62
  requirements:
63
- - - '>='
63
+ - - ">="
64
64
  - !ruby/object:Gem::Version
65
65
  version: '0'
66
66
  required_rubygems_version: !ruby/object:Gem::Requirement
67
67
  requirements:
68
- - - '>='
68
+ - - ">="
69
69
  - !ruby/object:Gem::Version
70
70
  version: '0'
71
71
  requirements: []
72
72
  rubyforge_project:
73
- rubygems_version: 2.0.14.1
73
+ rubygems_version: 2.6.12
74
74
  signing_key:
75
75
  specification_version: 4
76
76
  summary: CoinMarketCap frontend for ruby-money