aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord
diff options
context:
space:
mode:
authorRyuta Kamizono <kamipo@gmail.com>2017-09-08 08:10:14 +0900
committerRyuta Kamizono <kamipo@gmail.com>2017-09-08 08:10:14 +0900
commitb442cb0d915f64315e6c43aa19719df74a29fe5e (patch)
tree37a5237e11336c1364cb7528d2b4113e3088365b /activerecord
parenta6860e0f0f2df99ac3859433b471692e6b598cbf (diff)
downloadrails-b442cb0d915f64315e6c43aa19719df74a29fe5e.tar.gz
rails-b442cb0d915f64315e6c43aa19719df74a29fe5e.tar.bz2
rails-b442cb0d915f64315e6c43aa19719df74a29fe5e.zip
Remove unnecessary `join_type` in `AssociationScope`
This method was moved from `JoinHelper` in 0fddc3c1, but it is only used for `table.create_join` in the internal and `Nodes::InnerJoin` is default join klass. So it is not needed to pass it explicitly.
Diffstat (limited to 'activerecord')
-rw-r--r--activerecord/lib/active_record/associations/association_scope.rb6
1 files changed, 1 insertions, 5 deletions
diff --git a/activerecord/lib/active_record/associations/association_scope.rb b/activerecord/lib/active_record/associations/association_scope.rb
index ae3767466d..b2dc044312 100644
--- a/activerecord/lib/active_record/associations/association_scope.rb
+++ b/activerecord/lib/active_record/associations/association_scope.rb
@@ -30,10 +30,6 @@ module ActiveRecord
add_constraints(scope, owner, chain)
end
- def join_type
- Arel::Nodes::InnerJoin
- end
-
def self.get_bind_values(owner, chain)
binds = []
last_reflection = chain.last
@@ -59,7 +55,7 @@ module ActiveRecord
private
def join(table, constraint)
- table.create_join(table, table.create_on(constraint), join_type)
+ table.create_join(table, table.create_on(constraint))
end
def last_chain_scope(scope, reflection, owner)