graphiti 1.2.39 → 1.2.40
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/graphiti/sideload.rb +6 -1
- data/lib/graphiti/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d10b110934848ed53d75bb0b8595f73c50524833818d39dc53f3859c393d342b
|
4
|
+
data.tar.gz: a28ab64e8453486628ee93d131914479c24d60ade77e8dd201030bbe68dd055c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1d1d78896c8079cfbc4e74f3f6b754047a5c597adfe87023340adae7c56029ef60873c5cfe91fd099d7aac7965db7048dfb45e10efa8d29a39e4cdbfc19d99e3
|
7
|
+
data.tar.gz: f563f24c252c72e49a8bc8ba52ac8a6c5ab814d7699817fce981adee68dc74edc6e3dc82f2a5fdc5986e1b07411fbad776df5bba7099baeae930b305a03e0b92
|
data/lib/graphiti/sideload.rb
CHANGED
@@ -137,11 +137,16 @@ module Graphiti
|
|
137
137
|
end
|
138
138
|
|
139
139
|
def link_extra_fields
|
140
|
+
return unless context&.respond_to?(:params)
|
141
|
+
|
140
142
|
extra_fields_name = [association_name, resource.type].find { |param|
|
141
143
|
context.params.dig(:extra_fields, param)
|
142
144
|
}
|
143
145
|
|
144
|
-
|
146
|
+
if extra_fields_name
|
147
|
+
extra_fields = context.params.dig(:extra_fields, extra_fields_name)
|
148
|
+
{resource.type => extra_fields}
|
149
|
+
end
|
145
150
|
end
|
146
151
|
|
147
152
|
# The parent resource is a remote,
|
data/lib/graphiti/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: graphiti
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.2.
|
4
|
+
version: 1.2.40
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Lee Richmond
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-
|
11
|
+
date: 2021-04-13 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: jsonapi-serializable
|