forest_liana 2.0.1 → 2.0.2
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: 454283c8971492a55f01569974efa146b9b8adc2
|
4
|
+
data.tar.gz: 972f439e41f2f6278e6c31dee4754a31c7bc734f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3e5f995173c4f58f4f37593eee943c619b674c845551bb5972d43445ada79814dfb7d625e1eaa0a5fb6ee000b8ce99e195b17b607e76ce4e2f26e2f33d5e1914
|
7
|
+
data.tar.gz: 4756a39195e5055dd5a55b26d61d577d106586c7c27e2805408cfaf6b43bc585749d3d4f11933623df516b12304745b6114b353cc601c48e71c2583afc7c4520
|
@@ -13,9 +13,7 @@ module ForestLiana
|
|
13
13
|
|
14
14
|
# NOTICE: Create the serializer in the UserSpace to avoid conflicts with
|
15
15
|
# serializer created from integrations, actions, segments, etc.
|
16
|
-
|
17
|
-
ForestLiana::UserSpace.const_set(serializer_name, serializer)
|
18
|
-
end
|
16
|
+
ForestLiana::UserSpace.const_set(serializer_name, serializer)
|
19
17
|
end
|
20
18
|
|
21
19
|
def self.get_serializer_name(active_record_class)
|
@@ -27,8 +27,7 @@ module ForestLiana
|
|
27
27
|
def controller_for(active_record_class)
|
28
28
|
controller = Class.new(ResourcesController) { }
|
29
29
|
|
30
|
-
ForestLiana::ControllerFactory.define_controller(active_record_class,
|
31
|
-
controller)
|
30
|
+
ForestLiana::ControllerFactory.define_controller(active_record_class, controller)
|
32
31
|
controller
|
33
32
|
end
|
34
33
|
end
|
@@ -79,11 +79,11 @@ module ForestLiana
|
|
79
79
|
# Monkey patch the find_serializer_class_name method to specify the
|
80
80
|
# good serializer to use.
|
81
81
|
::JSONAPI::Serializer.class_eval do
|
82
|
-
def self.find_serializer_class_name(
|
83
|
-
if
|
84
|
-
|
82
|
+
def self.find_serializer_class_name(record, options)
|
83
|
+
if record.respond_to?(:jsonapi_serializer_class_name)
|
84
|
+
record.jsonapi_serializer_class_name.to_s
|
85
85
|
else
|
86
|
-
ForestLiana::SerializerFactory.get_serializer_name(
|
86
|
+
ForestLiana::SerializerFactory.get_serializer_name(record.class)
|
87
87
|
end
|
88
88
|
end
|
89
89
|
end
|
data/lib/forest_liana/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: forest_liana
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.
|
4
|
+
version: 2.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Sandro Munda
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-12-
|
11
|
+
date: 2017-12-08 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|