activerecord-has_count 0.0.5 → 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: ffb8dbb43a6182ea418d3f984bce272c260c9281
|
|
4
|
+
data.tar.gz: 7aa5927f002580f27aa43045f0e47ac2f3bef58b
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: bc66a7bf53b05c3103b1c37ca912ccdbc634296b3e38e50a3d0b98c115bbcaf289d817e704de6c23f70a869b48d42710d328e169502b78c8f5453fa43e43717b
|
|
7
|
+
data.tar.gz: 4c7288b358022b5ba972524058e9c2fb50f8b5895a704b733a7e4a8e8769872b8f5f66b74c8da349a82c32bfe65552d91907e0283cb05ecfb15af5b5f01334fd
|
|
@@ -16,7 +16,7 @@ module ActiveRecord
|
|
|
16
16
|
def klass_with_has_count
|
|
17
17
|
case macro
|
|
18
18
|
when :has_count
|
|
19
|
-
@klass ||= active_record.send(:compute_type, name_without_count.singularize.classify)
|
|
19
|
+
@klass ||= active_record.send(:compute_type, options[:class_name] || name_without_count.singularize.classify)
|
|
20
20
|
else
|
|
21
21
|
klass_without_has_count
|
|
22
22
|
end
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: activerecord-has_count
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.0
|
|
4
|
+
version: 0.1.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Takashi Kokubun
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2014-11-
|
|
11
|
+
date: 2014-11-20 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: activerecord
|