lean_tag 0.1.2 → 0.1.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 2a0c75bde470305b48d2afe443e04a4972f3dc3d
4
- data.tar.gz: 4ababb77581f5b879a7fedc3bc6c47e203cc6ad1
3
+ metadata.gz: 826bf0e70d6602d1652e50075eebb8cdc7a6954a
4
+ data.tar.gz: 1582db1e1b197c7aba0f15f3a87d67fdd4e240d0
5
5
  SHA512:
6
- metadata.gz: 6f115d263e884f5cca2abad2eb5220935f5e45d445733bf5c0b642dee4b18129b7b1ca98fe650f5f1eb353982ef548d1b5b4d31ac3b249fd230149a3f6bee9c3
7
- data.tar.gz: 43068f0a5f13703ca24a70ff53646b3d335e9e0c9ee187eba4c6acd05a3be8143c62827f62e509063d0a17197e5841f440dd9d6a60652fca3e38b263d5a7f695
6
+ metadata.gz: ff3b6bd7dbc748e48cebdbd4cbbecff204581cbe0f3fa9be61d6e2e25a2f220c8e220e7f77c63dfedab1615541940c3fa44874fca04365a9c2aca2f19a56f908
7
+ data.tar.gz: 2ca680df07bc3377d291be9c0903b60b83ae2bef91bbda84257478c86c992c4e3f23194fe46ba9f7dc047625f502712b5e14018761b81a30ec9a0da7d43e9eee
data/lib/lean_tag/tag.rb CHANGED
@@ -4,7 +4,7 @@ module LeanTag
4
4
  self.table_name = :tags
5
5
 
6
6
  has_many :records, through: :taggings
7
- has_many :taggings, class_name: "LeanTag::Tagging", inverse_of: :tag, counter_cache: true
7
+ has_many :taggings, class_name: "LeanTag::Tagging", inverse_of: :tag
8
8
 
9
9
  scope :ranked, -> { order("taggings_count DESC") }
10
10
 
@@ -4,7 +4,7 @@ module LeanTag
4
4
  self.table_name = :taggings
5
5
 
6
6
  belongs_to :record, polymorphic: true, inverse_of: :taggings
7
- belongs_to :tag, class_name: "LeanTag::Tag", inverse_of: :taggings
7
+ belongs_to :tag, class_name: "LeanTag::Tag", inverse_of: :taggings, counter_cache: :taggings_count
8
8
 
9
9
  validates :record_id, presence: true
10
10
  validates :record_type, presence: true
@@ -1,5 +1,5 @@
1
1
  module LeanTag
2
2
 
3
- VERSION = '0.1.2'
3
+ VERSION = '0.1.3'
4
4
 
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lean_tag
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 0.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Matt Ellis