Method: ActiveModel::NestedError#initialize
- Defined in:
- activemodel/lib/active_model/nested_error.rb
#initialize(base, inner_error, override_options = {}) ⇒ NestedError
Returns a new instance of NestedError.
8 9 10 11 12 13 14 15 |
# File 'activemodel/lib/active_model/nested_error.rb', line 8 def initialize(base, inner_error, = {}) @base = base @inner_error = inner_error @attribute = .fetch(:attribute) { inner_error.attribute } @type = .fetch(:type) { inner_error.type } @raw_type = inner_error.raw_type = inner_error. end |