Exception: Related::ValidationsFailed
- Inherits:
-
RelatedException
- Object
- RuntimeError
- RelatedException
- Related::ValidationsFailed
- Defined in:
- lib/related/exceptions.rb
Instance Attribute Summary collapse
-
#object ⇒ Object
readonly
Returns the value of attribute object.
Instance Method Summary collapse
-
#initialize(object) ⇒ ValidationsFailed
constructor
A new instance of ValidationsFailed.
Constructor Details
#initialize(object) ⇒ ValidationsFailed
Returns a new instance of ValidationsFailed.
7 8 9 10 11 |
# File 'lib/related/exceptions.rb', line 7 def initialize(object) @object = object errors = @object.errors..to_sentence super(errors) end |
Instance Attribute Details
#object ⇒ Object (readonly)
Returns the value of attribute object.
6 7 8 |
# File 'lib/related/exceptions.rb', line 6 def object @object end |