Module: Errorio::ErrorObjectsMethods
- Defined in:
- lib/errorio.rb
Overview
Methods for Error object
Instance Method Summary collapse
Instance Method Details
#to_e ⇒ Object
196 197 198 199 200 201 202 203 204 205 |
# File 'lib/errorio.rb', line 196 def to_e result = [] @errors.each do |err| msg = err..key?(:message) ? err.[:message] : err. err_obj = err..merge(key: err.attribute, type: err.type, message: msg) result << err_obj end result end |