mirror of
https://github.com/maybe-finance/maybe.git
synced 2025-08-04 21:15:19 +02:00
Refactor: Use native error i18n lookup (#1076)
This commit is contained in:
parent
150fce41a8
commit
14c4b9e93c
15 changed files with 103 additions and 26 deletions
|
@ -40,7 +40,8 @@ class TimeSeries::Value
|
|||
|
||||
def value_must_be_of_known_type
|
||||
unless value.is_a?(Money) || value.is_a?(Numeric)
|
||||
errors.add :value, "must be a Money or Numeric"
|
||||
# i18n-tasks-use t('activemodel.errors.models.time_series/value.attributes.value.must_be_a_money_or_numeric')
|
||||
errors.add :value, must_be_a_money_or_numeric
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue