apollo-federation 2.2.1 → 2.2.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
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c2c05610a6aa19695ff6a2cfc9eda7bf5ba8053f8e5ede044613962136bb3e50
|
4
|
+
data.tar.gz: efb8627e921a44420721b8da4e9d71380826f42b7aae6596a7c766daac4bda88
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 35ed590fc3fdd628557bbe31c70140cef552f5174468cade36a61f78249d9b26a98d10062357487f9970f713d96f33ad379c77c475d355f0b51b7516a3ad5a61
|
7
|
+
data.tar.gz: 4463e67bf8a4396925fc327131757b365ede5834d29dc9836fecbd47f224b149c0c729b7c9cd6a19dbd7317cfd29ff4fdba0744aaa2829014394bec73f5bbeb7
|
data/CHANGELOG.md
CHANGED
@@ -1,3 +1,10 @@
|
|
1
|
+
## [2.2.2](https://github.com/Gusto/apollo-federation-ruby/compare/v2.2.1...v2.2.2) (2022-03-15)
|
2
|
+
|
3
|
+
|
4
|
+
### Bug Fixes
|
5
|
+
|
6
|
+
* add a ruby version file ([#185](https://github.com/Gusto/apollo-federation-ruby/issues/185)) ([b46346b](https://github.com/Gusto/apollo-federation-ruby/commit/b46346bbbccc51d77e67ce43f411a6ee72f1a1d5))
|
7
|
+
|
1
8
|
## [2.2.1](https://github.com/Gusto/apollo-federation-ruby/compare/v2.2.0...v2.2.1) (2022-03-08)
|
2
9
|
|
3
10
|
|
@@ -38,7 +38,8 @@ module ApolloFederation
|
|
38
38
|
end
|
39
39
|
|
40
40
|
# TODO: What if the type is an interface?
|
41
|
-
type_class = type
|
41
|
+
type_class = class_of_type(type)
|
42
|
+
|
42
43
|
if type_class.respond_to?(:resolve_reference)
|
43
44
|
result = type_class.resolve_reference(reference, context)
|
44
45
|
else
|
@@ -55,5 +56,15 @@ module ApolloFederation
|
|
55
56
|
end
|
56
57
|
end
|
57
58
|
end
|
59
|
+
|
60
|
+
private
|
61
|
+
|
62
|
+
def class_of_type(type)
|
63
|
+
if defined?(GraphQL::ObjectType) && type.is_a?(GraphQL::ObjectType)
|
64
|
+
type.metadata[:type_class]
|
65
|
+
else
|
66
|
+
type
|
67
|
+
end
|
68
|
+
end
|
58
69
|
end
|
59
70
|
end
|
@@ -56,8 +56,6 @@ module ApolloFederation
|
|
56
56
|
def merge_directives(node, type)
|
57
57
|
if type.is_a?(ApolloFederation::HasDirectives)
|
58
58
|
directives = type.federation_directives
|
59
|
-
elsif type.is_a?(GraphQL::Define::InstanceDefinable)
|
60
|
-
directives = type.metadata[:federation_directives]
|
61
59
|
else
|
62
60
|
directives = []
|
63
61
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: apollo-federation
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.2.
|
4
|
+
version: 2.2.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Noa Elad
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2022-03-
|
12
|
+
date: 2022-03-15 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: graphql
|