aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/lib/active_record/relation.rb
diff options
context:
space:
mode:
authorJon Leighton <j@jonathanleighton.com>2012-04-13 10:43:12 +0100
committerJon Leighton <j@jonathanleighton.com>2012-04-13 13:17:42 +0100
commite4f0fbd994ab0c333e615be68a8d40593c7058e3 (patch)
tree09a50548e6f2d65310361a662f7ebb0c1953cff2 /activerecord/lib/active_record/relation.rb
parenta258c27653c6a57b62b30d34791b8bb671248150 (diff)
downloadrails-e4f0fbd994ab0c333e615be68a8d40593c7058e3.tar.gz
rails-e4f0fbd994ab0c333e615be68a8d40593c7058e3.tar.bz2
rails-e4f0fbd994ab0c333e615be68a8d40593c7058e3.zip
we have no need for the ASSOCIATION_METHODS constant
Diffstat (limited to 'activerecord/lib/active_record/relation.rb')
-rw-r--r--activerecord/lib/active_record/relation.rb11
1 files changed, 7 insertions, 4 deletions
diff --git a/activerecord/lib/active_record/relation.rb b/activerecord/lib/active_record/relation.rb
index b007b8c168..0d7da67c98 100644
--- a/activerecord/lib/active_record/relation.rb
+++ b/activerecord/lib/active_record/relation.rb
@@ -6,9 +6,12 @@ module ActiveRecord
# = Active Record Relation
class Relation
JoinOperation = Struct.new(:relation, :join_class, :on)
- ASSOCIATION_METHODS = [:includes, :eager_load, :preload]
- MULTI_VALUE_METHODS = [:select, :group, :order, :joins, :where, :having, :bind, :references]
- SINGLE_VALUE_METHODS = [:limit, :offset, :lock, :readonly, :from, :reordering, :reverse_order, :uniq]
+
+ MULTI_VALUE_METHODS = [:includes, :eager_load, :preload, :select, :group,
+ :order, :joins, :where, :having, :bind, :references]
+
+ SINGLE_VALUE_METHODS = [:limit, :offset, :lock, :readonly, :from, :reordering,
+ :reverse_order, :uniq]
include FinderMethods, Calculations, SpawnMethods, QueryMethods, Batches, Explain, Delegation
@@ -25,7 +28,7 @@ module ActiveRecord
@default_scoped = false
SINGLE_VALUE_METHODS.each {|v| instance_variable_set(:"@#{v}_value", nil)}
- (ASSOCIATION_METHODS + MULTI_VALUE_METHODS).each {|v| instance_variable_set(:"@#{v}_values", [])}
+ MULTI_VALUE_METHODS.each {|v| instance_variable_set(:"@#{v}_values", [])}
@extensions = []
@create_with_value = {}
end