mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
947a5de75d
As the API doc shows, `references` should be given table names. https://api.rubyonrails.org/classes/ActiveRecord/QueryMethods.html#method-i-references However, people (and test cases in the our codebase) sometimes give association names for `references`. Since the API example and all test cases in the codebase use symbols as arguments, so I regarded symbols as user given values in #40106. But as #40743 indicates, people also use string association names, it would have unexpected side-effect especially if singular association names given. As much as possible to avoid to use user given values, mark internal references for `where` and use only them for join aliases. Fixes #40743. |
||
---|---|---|
.. | ||
builder | ||
join_dependency | ||
preloader | ||
alias_tracker.rb | ||
association.rb | ||
association_scope.rb | ||
belongs_to_association.rb | ||
belongs_to_polymorphic_association.rb | ||
collection_association.rb | ||
collection_proxy.rb | ||
foreign_association.rb | ||
has_many_association.rb | ||
has_many_through_association.rb | ||
has_one_association.rb | ||
has_one_through_association.rb | ||
join_dependency.rb | ||
preloader.rb | ||
singular_association.rb | ||
through_association.rb |