Exception: Secretariat::ValidationError

Inherits:
StandardError
  • Object
show all
Defined in:
lib/secretariat/validation_error.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(reason, errors = []) ⇒ ValidationError

Returns a new instance of ValidationError.



20
21
22
23
# File 'lib/secretariat/validation_error.rb', line 20

def initialize(reason, errors = [])
  super(reason)
  @errors = errors
end

Instance Attribute Details

#errorsObject (readonly)

Returns the value of attribute errors.



19
20
21
# File 'lib/secretariat/validation_error.rb', line 19

def errors
  @errors
end