diff options
author | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2014-06-26 10:27:13 -0300 |
---|---|---|
committer | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2014-06-26 10:27:13 -0300 |
commit | 031588ebe6b449bcba6e3becfaff6978ba10464a (patch) | |
tree | 179a789fd65ddc4c157f6bb088002a465755e6a8 /activerecord/test/models/post.rb | |
parent | e8003c7274c4049f409740b587e4e9e1f3df37f7 (diff) | |
parent | d730e374ca99a60b08c75aab7b0ed8a846a34924 (diff) | |
download | rails-031588ebe6b449bcba6e3becfaff6978ba10464a.tar.gz rails-031588ebe6b449bcba6e3becfaff6978ba10464a.tar.bz2 rails-031588ebe6b449bcba6e3becfaff6978ba10464a.zip |
Merge pull request #15754 from sgrif/sg-deprecate-hmt-counter-cache
Deprecate automatic counter caches on has_many :through
Diffstat (limited to 'activerecord/test/models/post.rb')
-rw-r--r-- | activerecord/test/models/post.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/test/models/post.rb b/activerecord/test/models/post.rb index 5f01ab0a82..a29858213b 100644 --- a/activerecord/test/models/post.rb +++ b/activerecord/test/models/post.rb @@ -88,7 +88,7 @@ class Post < ActiveRecord::Base has_and_belongs_to_many :categories has_and_belongs_to_many :special_categories, :join_table => "categories_posts", :association_foreign_key => 'category_id' - has_many :taggings, :as => :taggable + has_many :taggings, :as => :taggable, :counter_cache => :tags_count has_many :tags, :through => :taggings do def add_joins_and_select select('tags.*, authors.id as author_id') |