diff options
author | Sean Griffin <sean@thoughtbot.com> | 2015-01-25 16:40:23 -0700 |
---|---|---|
committer | Sean Griffin <sean@thoughtbot.com> | 2015-01-25 16:40:23 -0700 |
commit | 87726b93d4fd447671d0b20ae2ec37a9eb4f2fd4 (patch) | |
tree | 388e0a8442b85432310a3e116f7c61ddc05fc5bc | |
parent | def2879d7d187df945d77c1028d4cef588cbc8a0 (diff) | |
download | rails-87726b93d4fd447671d0b20ae2ec37a9eb4f2fd4.tar.gz rails-87726b93d4fd447671d0b20ae2ec37a9eb4f2fd4.tar.bz2 rails-87726b93d4fd447671d0b20ae2ec37a9eb4f2fd4.zip |
Remove references to `:bind` in `except`
Bind values are no longer a thing, so this is unnecessary.
-rw-r--r-- | activerecord/lib/active_record/associations/association_scope.rb | 2 | ||||
-rw-r--r-- | activerecord/lib/active_record/relation/spawn_methods.rb | 3 |
2 files changed, 1 insertions, 4 deletions
diff --git a/activerecord/lib/active_record/associations/association_scope.rb b/activerecord/lib/active_record/associations/association_scope.rb index d06b7b3508..3d71e73b3c 100644 --- a/activerecord/lib/active_record/associations/association_scope.rb +++ b/activerecord/lib/active_record/associations/association_scope.rb @@ -160,7 +160,7 @@ module ActiveRecord item = eval_scope(reflection.klass, scope_chain_item, owner) if scope_chain_item == refl.scope - scope.merge! item.except(:where, :includes, :bind) + scope.merge! item.except(:where, :includes) end reflection.all_includes do diff --git a/activerecord/lib/active_record/relation/spawn_methods.rb b/activerecord/lib/active_record/relation/spawn_methods.rb index 01bddea6c9..dd3610d7aa 100644 --- a/activerecord/lib/active_record/relation/spawn_methods.rb +++ b/activerecord/lib/active_record/relation/spawn_methods.rb @@ -58,9 +58,6 @@ module ActiveRecord # Post.order('id asc').only(:where) # discards the order condition # Post.order('id asc').only(:where, :order) # uses the specified order def only(*onlies) - if onlies.any? { |o| o == :where } - onlies << :bind - end relation_with values.slice(*onlies) end |