oexrwrapper 0.1.2 → 0.1.3
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.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/README.md +2 -1
- data/lib/oexrwrapper/objects/currencies.rb +1 -1
- data/lib/oexrwrapper/objects/currency.rb +10 -0
- data/lib/oexrwrapper/resources/currencies.rb +6 -1
- data/lib/oexrwrapper/version.rb +1 -1
- data/lib/oexrwrapper.rb +1 -0
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a706334a795ad7d94d7fbe59423811794cdf966a92630dd3f11fae69db2b8eb8
|
4
|
+
data.tar.gz: 5ffb6ea6bedfb17ded3dc517c4f9ac4238d9a19d23cc1d4b035542210230358f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ff20781ab6ada74c7e4baaffb1f6c91e87cd9cd6fa100a69a020cd20a038891f0dcbd59cceeedfa980d5acc65b44def461867f0f13684406397a3625d41a60ae
|
7
|
+
data.tar.gz: 15adf92eee3fb001809f3d45cda3f19df16f0b6f28817f767c3e0e194c315e74179dd3e33446d322e297273c1e4da7845429b40967ad6263fb06d838bb485c51
|
data/Gemfile.lock
CHANGED
data/README.md
CHANGED
@@ -1,6 +1,7 @@
|
|
1
1
|
# OEXRWrapper
|
2
2
|
[](https://codeclimate.com/github/sdglhm/OEXRWrapper/maintainability)
|
3
|
-

|
3
|
+

|
4
|
+
[](https://badge.fury.io/rb/oexrwrapper)
|
4
5
|
Simple gem written for learning purposes. Fetches latest exchange rate from OpenExchangeRates.org and returns value.
|
5
6
|
|
6
7
|
## ToDo
|
@@ -1,7 +1,12 @@
|
|
1
1
|
module OEXRWrapper
|
2
2
|
class CurrenciesResources < Resource
|
3
3
|
def retrieve
|
4
|
-
|
4
|
+
currency_array = Array.new
|
5
|
+
get_request('currencies').body.each do |currency|
|
6
|
+
currency_array.push(Currency.new(currency[0], currency[1]))
|
7
|
+
end
|
8
|
+
|
9
|
+
Currencies.new currency_array
|
5
10
|
end
|
6
11
|
|
7
12
|
def code_to_string(code)
|
data/lib/oexrwrapper/version.rb
CHANGED
data/lib/oexrwrapper.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: oexrwrapper
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Lahiru Himesh Madusanka
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-03-
|
11
|
+
date: 2022-03-29 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: faraday
|
@@ -45,6 +45,7 @@ files:
|
|
45
45
|
- lib/oexrwrapper/error.rb
|
46
46
|
- lib/oexrwrapper/object.rb
|
47
47
|
- lib/oexrwrapper/objects/currencies.rb
|
48
|
+
- lib/oexrwrapper/objects/currency.rb
|
48
49
|
- lib/oexrwrapper/objects/latest.rb
|
49
50
|
- lib/oexrwrapper/resource.rb
|
50
51
|
- lib/oexrwrapper/resources/currencies.rb
|