Flowdock
method

join_for_table_name

Importance_0
v2.2.1 - Show latest stable - 0 notes - Class: ActiveRecord::Associations::ClassMethods::JoinDependency
join_for_table_name(table_name) public

No documentation

This method has no description. You can help the Ruby on Rails community by adding new notes.

Hide source
# File activerecord/lib/active_record/associations.rb, line 1873
          def join_for_table_name(table_name)
            join = (@joins.select{|j|j.aliased_table_name == table_name.gsub(/^\"(.*)\"$/){$1} }.first) rescue nil
            return join unless join.nil?
            @joins.select{|j|j.is_a?(JoinAssociation) && j.aliased_join_table_name == table_name.gsub(/^\"(.*)\"$/){$1} }.first rescue nil
          end
Register or log in to add new notes.