Exception: ActiveRecord::HasManyThroughAssociationNotFoundError

Inherits:
ActiveRecordError show all
Defined in:
activerecord/lib/active_record/associations.rb

Overview

:nodoc:

Instance Method Summary collapse

Constructor Details

#initialize(owner_class_name = nil, reflection = nil) ⇒ HasManyThroughAssociationNotFoundError

Returns a new instance of HasManyThroughAssociationNotFoundError.



28
29
30
31
32
33
34
# File 'activerecord/lib/active_record/associations.rb', line 28

def initialize(owner_class_name = nil, reflection = nil)
  if owner_class_name && reflection
    super("Could not find the association #{reflection.options[:through].inspect} in model #{owner_class_name}")
  else
    super("Could not find the association.")
  end
end