redisize 0.1.3 → 0.1.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/redisize/version.rb +1 -1
- data/lib/redisize.rb +7 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 5b7b65e687f5003dac2ba7e92d42450cea066554ce88bccb49c210ff0a413d41
|
4
|
+
data.tar.gz: 95e775070c058d4f3804d03bb082969146c6e5402aec915d489a11eca262214e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b26a2aa8e95fd8de86db627fb45207af2bbebaaaf5fc468b2b4ed8d2f9675a83f8e4852c8d1adbd1150a03bd4dd00a588d2c67c9b5a3ed30f30ddb7f05544c72
|
7
|
+
data.tar.gz: b2493b59261c6c0cbe9962c6dd7e97b635de114695d77373c56608a723b78d9f2e655d59605c2788b4ca978f0e2161b0177c3db7c3c6673126af95dd5e9f1d19
|
data/lib/redisize/version.rb
CHANGED
data/lib/redisize.rb
CHANGED
@@ -291,7 +291,13 @@ module Redisize
|
|
291
291
|
|
292
292
|
module ClassMethods
|
293
293
|
def polymorphic_base_name
|
294
|
-
|
294
|
+
base_name = base_class.to_s
|
295
|
+
|
296
|
+
if base_name == polymorphic_name
|
297
|
+
polymorphic_name
|
298
|
+
else
|
299
|
+
(base_class.to_s.split("::")[0...-1] + [polymorphic_name]).join("::")
|
300
|
+
end
|
295
301
|
end
|
296
302
|
|
297
303
|
# self -> model class
|