rents 1.0.7 → 1.0.8
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/rents/currency.rb +1 -1
- data/lib/rents/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f41cbea94db8e8d59e5f256178b76ff93d80b65c
|
4
|
+
data.tar.gz: d6930c7f2b0d07cd5f986a57c7ca16133d08be2d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 01fe8b915aba29a8af330aa19c7603da9a1d3a78b127c25617388f40f6eb744dd0fd86b679351b9797671f60f0d03fab6b18c96058d37f50896e5fef5c348102
|
7
|
+
data.tar.gz: c84e85e7884e69a12931e1ca2812158826534f06a9bacdf533f8839fb786919c0e8320cdcd6465adcc3acddfe691052d7d6eefb17d34c12562040229865b9336
|
data/lib/rents/currency.rb
CHANGED
@@ -6,8 +6,8 @@ module Rents
|
|
6
6
|
# Check invalid entry
|
7
7
|
return nil if amount.nil?
|
8
8
|
return amount.to_s if amount.is_a?Integer
|
9
|
-
return amount if amount.is_a?(String) && amount.index('.').nil? && amount.index(',').nil?
|
10
9
|
amount = format('%.2f', amount) if amount.to_s.float?
|
10
|
+
return amount if amount.is_a?(String) && amount.index('.').nil? && amount.index(',').nil?
|
11
11
|
|
12
12
|
if amount.is_a?String
|
13
13
|
return amount if amount.index('.').nil? && amount.index(',').nil?
|
data/lib/rents/version.rb
CHANGED