diff options
author | Jeremy Kemper <jeremy@bitsweat.net> | 2007-05-23 06:35:08 +0000 |
---|---|---|
committer | Jeremy Kemper <jeremy@bitsweat.net> | 2007-05-23 06:35:08 +0000 |
commit | 9f51eb24724df1e7c1bef004111ab4faca717378 (patch) | |
tree | cc9acdafdaae757c2c642dc54d3abed7c7c44a37 | |
parent | ba7dc5d42160271ee0d321ee4802c0ddfb5d1ab2 (diff) | |
download | rails-9f51eb24724df1e7c1bef004111ab4faca717378.tar.gz rails-9f51eb24724df1e7c1bef004111ab4faca717378.tar.bz2 rails-9f51eb24724df1e7c1bef004111ab4faca717378.zip |
Fix :through docs wrecked up by [6777]. Closes #4961.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6817 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
-rwxr-xr-x | activerecord/lib/active_record/associations.rb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/associations.rb b/activerecord/lib/active_record/associations.rb index c72024d5f3..0e8a48f2a0 100755 --- a/activerecord/lib/active_record/associations.rb +++ b/activerecord/lib/active_record/associations.rb @@ -608,7 +608,8 @@ module ActiveRecord # include the joined columns. # * <tt>:as</tt>: Specifies a polymorphic interface (See #belongs_to). # * <tt>:through</tt>: Specifies a Join Model to perform the query through. Options for <tt>:class_name</tt> and <tt>:foreign_key</tt> - # are ignored, as the association uses the source reflection. + # are ignored, as the association uses the source reflection. You can only use a <tt>:through</tt> query through a <tt>belongs_to</tt> + # or <tt>has_many</tt> association on the join model. # * <tt>:source</tt>: Specifies the source association name used by <tt>has_many :through</tt> queries. Only use it if the name cannot be # inferred from the association. <tt>has_many :subscribers, :through => :subscriptions</tt> will look for either +:subscribers+ or # +:subscriber+ on +Subscription+, unless a +:source+ is given. |