active_tools 0.0.16 → 0.0.17
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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c5ba5b8fe10ee75b87f277afa16d735304c811a8
|
4
|
+
data.tar.gz: 26e33d56068d147c44c00b5f6aab47b1dd062a08
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f3a0980c7359b0d2d42a1845c435f225cfd2f1d2aaaa112a13962238830c1fc1edc45db797c18638dc130457b7c171c6f82a03f308c88cde5f115663f8468704
|
7
|
+
data.tar.gz: 62fc295205c2a7f3fbbd0eaf2ee8410ea9132df34c4e13b4e268d94f6b9348820f3314846526c7f6921110be362e869136107fcff1b8518f095951fdc1f35697
|
@@ -32,8 +32,8 @@ module ActiveTools
|
|
32
32
|
if (@_after_create_custom_counter_called ||= false)
|
33
33
|
@_after_create_custom_counter_called = false
|
34
34
|
elsif !new_record? && record_changed
|
35
|
-
model = reflection.polymorphic
|
36
|
-
model_was = reflection.polymorphic
|
35
|
+
model = reflection.options[:polymorphic] ? attribute(reflection.foreign_type).try(:constantize) : reflection.klass
|
36
|
+
model_was = reflection.options[:polymorphic] ? attribute_was(reflection.foreign_type).try(:constantize) : reflection.klass
|
37
37
|
foreign_key = attribute(reflection.foreign_key)
|
38
38
|
foreign_key_was = attribute_was(reflection.foreign_key)
|
39
39
|
|
data/lib/active_tools/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: active_tools
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.17
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Valery Kvon
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-
|
11
|
+
date: 2014-09-06 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|