Exception: Mongoid::Errors::Validations
- Defined in:
- lib/mongoid/errors.rb
Overview
Raised when a persisence method ending in ! fails validation.
Instance Method Summary collapse
-
#initialize(errors) ⇒ Validations
constructor
A new instance of Validations.
- #message ⇒ Object
Constructor Details
#initialize(errors) ⇒ Validations
Returns a new instance of Validations.
24 25 26 |
# File 'lib/mongoid/errors.rb', line 24 def initialize(errors) @errors = errors end |
Instance Method Details
#message ⇒ Object
27 28 29 |
# File 'lib/mongoid/errors.rb', line 27 def "Validation failed: #{@errors.}" end |