jsonapi_compliable 0.5.5 → 0.5.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/gemfiles/rails_4.gemfile.lock +1 -1
- data/gemfiles/rails_5.gemfile.lock +1 -1
- data/lib/jsonapi_compliable/adapters/abstract.rb +4 -0
- data/lib/jsonapi_compliable/adapters/active_record.rb +4 -0
- data/lib/jsonapi_compliable/resource.rb +4 -0
- data/lib/jsonapi_compliable/scope.rb +1 -3
- data/lib/jsonapi_compliable/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c1a466dbd616c05cad9dd31c7c57904056e86e7a
|
4
|
+
data.tar.gz: ed4007bed09c929be5a54b1e65d8da25721b8b61
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: fd5d8efef4d85afae6f027f89ac1082e28041b6c78cd24a7da33a5e2474132f392b0c97048877fc1ed505ecb943d5a9a587486fc7b87087b34d42a7c9e874f7f
|
7
|
+
data.tar.gz: 56ceebd8d57413fd798fabe9bb3940f8c73a5bc7c8e3bb9f0d709a77e75f62e261c344a23536c317cd1e214454a1dc5ced7cd55e4829cca9b3d46d315b305e7c
|
@@ -22,9 +22,7 @@ module JsonapiCompliable
|
|
22
22
|
if @query.zero_results?
|
23
23
|
[]
|
24
24
|
else
|
25
|
-
resolved = @object
|
26
|
-
# TODO - configurable resolve function
|
27
|
-
resolved = @object.to_a if defined?(ActiveRecord) && @object.is_a?(ActiveRecord::Relation)
|
25
|
+
resolved = @resource.resolve(@object)
|
28
26
|
sideload(resolved, query_hash[:include]) if query_hash[:include]
|
29
27
|
resolved
|
30
28
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: jsonapi_compliable
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.5.
|
4
|
+
version: 0.5.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Lee Richmond
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: exe
|
11
11
|
cert_chain: []
|
12
|
-
date: 2017-03-
|
12
|
+
date: 2017-03-08 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: jsonapi-serializable
|