avromatic 0.9.0.rc3 → 0.9.0.rc4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/avromatic/model/nested_models.rb +8 -7
- data/lib/avromatic/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: 1d65e7071a11c5a0b6ffa58c3d495b8b8a551461
|
4
|
+
data.tar.gz: fe9c6e799c8bc16e05520b6de4d3960030e6ae8b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 8277129ab8bdc6f7265f798654d04029b1ca58065b33581d786c1d00ec007ca89d5b9dd1329c70d509800ebbeb558f0d2d2b35e9e0e7220ac21cdf6c28763579
|
7
|
+
data.tar.gz: 70a0355e84f6d7ddffb2a12b5085f1b3ef3d5b9e840bcbf82c855de1dc01b10c169c7fc5434165a459a6e6f76e738f6131915a40c547f7bb93ec61a2f7207d40
|
@@ -14,19 +14,20 @@ module Avromatic
|
|
14
14
|
if nested_models.registered?(fullname)
|
15
15
|
nested_models[fullname]
|
16
16
|
else
|
17
|
-
|
18
|
-
|
19
|
-
register: true)
|
20
|
-
# Register the generated model with Axiom to prevent it being
|
21
|
-
# treated as a BasicObject.
|
22
|
-
# See https://github.com/solnic/virtus/issues/284#issuecomment-56405137
|
23
|
-
Axiom::Types::Object.new { primitive(nested_model) }
|
17
|
+
Avromatic::Model.model(schema: schema,
|
18
|
+
nested_models: nested_models)
|
24
19
|
end
|
25
20
|
end
|
26
21
|
|
27
22
|
# Register this model if it can be used as a nested model.
|
28
23
|
def register!
|
29
24
|
if key_avro_schema.nil? && value_avro_schema.type_sym == :record
|
25
|
+
# Register the generated model with Axiom to prevent it being
|
26
|
+
# treated as a BasicObject.
|
27
|
+
# See https://github.com/solnic/virtus/issues/284#issuecomment-56405137
|
28
|
+
nested_model = self
|
29
|
+
Axiom::Types::Object.new { primitive(nested_model) }
|
30
|
+
|
30
31
|
nested_models.register(self)
|
31
32
|
end
|
32
33
|
end
|
data/lib/avromatic/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: avromatic
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.9.0.
|
4
|
+
version: 0.9.0.rc4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Salsify Engineering
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-09-
|
11
|
+
date: 2016-09-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: avro
|