Class: Balloon::Validate::ProcessValidator
- Inherits:
-
ActiveModel::EachValidator
- Object
- ActiveModel::EachValidator
- Balloon::Validate::ProcessValidator
- Defined in:
- lib/balloon/validate.rb
Instance Method Summary collapse
Instance Method Details
#validate_each(record, attr_name, value) ⇒ Object
22 23 24 25 26 27 |
# File 'lib/balloon/validate.rb', line 22 def validate_each(record, attr_name, value) if e = record.send(:process_error) = (e. == e.class.to_s) ? :process_error : e. record.errors.add(attr_name, ) end end |