Skip to content

Commit 31fb82d

Browse files
sirwolfgangsunny
andauthored
Apply suggestions from code review
Co-authored-by: Sunny Ripert <sunny@sunfox.org>
1 parent a6389d0 commit 31fb82d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/money/money.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -310,7 +310,7 @@ def self.from_amount(amount, currency = default_currency, options = {})
310310
raise ArgumentError, "'amount' must be numeric" unless Numeric === amount
311311

312312
currency = Currency.wrap(currency) || Money.default_currency
313-
raise Currency::NoCurrency, 'must be provide a currency' if currency.nil?
313+
raise Currency::NoCurrency, 'must provide a currency' if currency.nil?
314314

315315
value = amount.to_d * currency.subunit_to_unit
316316
new(value, currency, options)
@@ -356,7 +356,7 @@ def initialize(obj, currency = Money.default_currency, options = {})
356356

357357
# BigDecimal can be Infinity and NaN, money of that amount does not make sense
358358
raise ArgumentError, 'must be initialized with a finite value' unless @fractional.finite?
359-
raise Currency::NoCurrency, 'must be provide a currency' if @currency.nil?
359+
raise Currency::NoCurrency, 'must provide a currency' if @currency.nil?
360360
end
361361

362362
# Assuming using a currency using dollars:

0 commit comments

Comments
 (0)