caprese 0.3.8.4 → 0.3.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/lib/caprese/controller/concerns/persistence.rb +10 -5
- data/lib/caprese/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: 28a1b59679204603c164782c10c0002cef6ed073
|
|
4
|
+
data.tar.gz: 8b46ce7a7852fea0fde43cf408708fd44af3602a
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 2ceadcd09bfe6e6ed5f1728cbe8ce14e2816b08bb9f384543213921d5739a16874ff2dbc1a6d3b855e81d970f89f1e489dd161eaf86ac94b252ff76cc2e2d7f6
|
|
7
|
+
data.tar.gz: b97612679b10bc804e693e1ab031de06476e03c701c42246221847ac81e947336fe81730f3c864b022f4723cd3ec2df37439f0498189c1279733cbd005e77cb0
|
data/CHANGELOG.md
CHANGED
|
@@ -275,11 +275,16 @@ module Caprese
|
|
|
275
275
|
if resource_identifier[:type]
|
|
276
276
|
# { type: '...', id: '...' }
|
|
277
277
|
if (id = resource_identifier[:id])
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
278
|
+
begin
|
|
279
|
+
get_record!(
|
|
280
|
+
resource_identifier[:type],
|
|
281
|
+
Caprese.config.resource_primary_key,
|
|
282
|
+
id
|
|
283
|
+
)
|
|
284
|
+
rescue Caprese::RecordNotFoundError => e
|
|
285
|
+
owner.errors.add(relationship_name, :not_found, t: { value: id })
|
|
286
|
+
nil
|
|
287
|
+
end
|
|
283
288
|
|
|
284
289
|
# { type: '...', attributes: { ... } }
|
|
285
290
|
elsif contains_constructable_data?(resource_identifier)
|
data/lib/caprese/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: caprese
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.3.
|
|
4
|
+
version: 0.3.9
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Nick Landgrebe
|
|
@@ -10,7 +10,7 @@ authors:
|
|
|
10
10
|
autorequire:
|
|
11
11
|
bindir: exe
|
|
12
12
|
cert_chain: []
|
|
13
|
-
date: 2017-02-
|
|
13
|
+
date: 2017-02-17 00:00:00.000000000 Z
|
|
14
14
|
dependencies:
|
|
15
15
|
- !ruby/object:Gem::Dependency
|
|
16
16
|
name: active_model_serializers
|