Class: LHS::Errors::Nested

Inherits:
Base
  • Object
show all
Defined in:
lib/lhs/errors/nested.rb

Instance Attribute Summary

Attributes inherited from Base

#message, #messages, #raw, #record

Instance Method Summary collapse

Methods inherited from Base

#[], #[]=, #add, #clear, #count, #each, #empty?, #get, #include?, #set, #size

Constructor Details

#initialize(errors, scope) ⇒ Nested

Returns a new instance of Nested.



4
5
6
7
8
9
# File 'lib/lhs/errors/nested.rb', line 4

def initialize(errors, scope)
  @raw = errors
  @messages = nest(errors.messages, scope)
  @message = errors.message
  @scope = scope
end