Exception: Dao::Validations::Error
- Defined in:
- lib/dao/validations.rb
Instance Attribute Summary collapse
-
#errors ⇒ Object
Returns the value of attribute errors.
Instance Method Summary collapse
-
#initialize(*args, &block) ⇒ Error
constructor
A new instance of Error.
- #object ⇒ Object
Constructor Details
#initialize(*args, &block) ⇒ Error
Returns a new instance of Error.
7 8 9 10 |
# File 'lib/dao/validations.rb', line 7 def initialize(*args, &block) @errors = args.shift if args.first.respond_to?(:full_messages) super(*args, &block) end |
Instance Attribute Details
#errors ⇒ Object
Returns the value of attribute errors.
5 6 7 |
# File 'lib/dao/validations.rb', line 5 def errors @errors end |
Instance Method Details
#object ⇒ Object
12 13 14 |
# File 'lib/dao/validations.rb', line 12 def object @errors.object if(@errors and @errors.respond_to?(:object)) end |