sevenwire-money 2.3.2 → 2.3.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.
- data/lib/money/money.rb +2 -2
- data/money.gemspec +1 -1
- metadata +1 -1
data/lib/money/money.rb
CHANGED
|
@@ -55,9 +55,9 @@ class Money
|
|
|
55
55
|
# By default, it will accept money in cents, however,
|
|
56
56
|
# you can also pass millicents by specifying :units => :millicents.
|
|
57
57
|
def initialize(money, *args)
|
|
58
|
-
raise Money::UnknownMonetaryValue, %{There is no way to turn "#{money}" into money} if !money.nil? && !money.is_a?(Numeric)
|
|
59
|
-
|
|
60
58
|
money = 0 if money.nil?
|
|
59
|
+
raise Money::UnknownMonetaryValue, %{There is no way to turn "#{money}" into money} if !money.is_a?(Numeric)
|
|
60
|
+
|
|
61
61
|
options = args.last.is_a?(Hash) ? args.pop : {}
|
|
62
62
|
|
|
63
63
|
if options[:units] == :millicents
|
data/money.gemspec
CHANGED