method
through_options
v3.1.0 -
Show latest stable
- Class:
ActiveRecord::Associations::Preloader::ThroughAssociation
through_options()private
No documentation available.
# File activerecord/lib/active_record/associations/preloader/through_association.rb, line 48
def through_options
through_options = {}
if options[:source_type]
through_options[:conditions] = { reflection.foreign_type => options[:source_type] }
else
if options[:conditions]
through_options[:include] = options[:include] || options[:source]
through_options[:conditions] = options[:conditions]
end
through_options[:order] = options[:order]
end
through_options
end