graphql-docs 0.4.0 → 0.4.1

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 4935d2987679ab16e3a82d24f4839b484dbc289e
4
- data.tar.gz: f4ddc20c6c2702e28b17c7c64648811d59a017ff
3
+ metadata.gz: c4d60df082629a2051e1f56910ae53e15ac0c2f4
4
+ data.tar.gz: abde3dbad6ce9687c95a31d2312fb98fedff8067
5
5
  SHA512:
6
- metadata.gz: d5bdeee0342d29830457a27c24924c14db9b4850fa75bc751abf449ae0c95c0dce091c5a7f4bea41423e864935c7ca82cda939bf81b7071154d3291db67844ca
7
- data.tar.gz: '018e1e9d4f837d7a326a430cbb75fe76cba0d5ff3731ef25b3dff54074ca6ab3bfb9ce596fd9ad9e95b030d9f0ab7bec9d550adbda28776ec1ffb13c970df09c'
6
+ metadata.gz: 8b97023604cff348beee6cbb17fd5175879232d7ac7fdae05711d0ff3cf0e640e97a2a2b78954ec1a4624cdda2ed47e4f183381b6cc21e2badf3065e8db575d4
7
+ data.tar.gz: c85ba82b15abdd9f46852e19b96e56e4324ccf28b1c2671be7eb65b5017642458003d88767179c07e21e861342ba345feb478596e9b2f224488bbe9b5e285d36
@@ -26,40 +26,40 @@ module GraphQLDocs
26
26
  type_name = ''
27
27
 
28
28
  if field['type']['kind'] == 'NON_NULL'
29
- type_name << '!'
30
-
31
29
  if !field['type']['ofType']['ofType'].nil?
32
30
  # we're going to be a list...but what kind?!
33
31
  type_name << '['
34
32
  if !field['type']['ofType']['ofType']['ofType'].nil?
35
- # A required list of required items: ![!Blah]
36
- if field['type']['ofType']['ofType']['kind'] == 'NON_NULL'
37
- type_name << '!'
38
- end
39
33
  type_path = field['type']['ofType']['ofType']['ofType']['kind']
40
34
  type_name << field['type']['ofType']['ofType']['ofType']['name']
41
35
  name_slug = field['type']['ofType']['ofType']['ofType']['name']
36
+ # A required list of required items: [Blah!]!
37
+ if field['type']['ofType']['ofType']['kind'] == 'NON_NULL'
38
+ type_name << '!'
39
+ end
42
40
  else
43
- # A required list of non-required items: ![Blah]
41
+ # A required list of non-required items: [Blah]!
44
42
  type_path = field['type']['ofType']['ofType']['kind']
45
43
  type_name << field['type']['ofType']['ofType']['name']
46
44
  name_slug = field['type']['ofType']['ofType']['name']
47
45
  end
48
46
  type_name << ']'
47
+ type_name << '!'
49
48
  else
50
- # Simple non-null item: !Blah
51
49
  type_path = field['type']['ofType']['kind']
52
50
  type_name << field['type']['ofType']['name']
53
51
  name_slug = field['type']['ofType']['name']
52
+ # Simple non-null item: Blah!
53
+ type_name << '!'
54
54
  end
55
55
  elsif field['type']['kind'] == 'LIST'
56
56
  type_name << '['
57
57
  if field['type']['ofType']['kind'] == 'NON_NULL'
58
- # Nullable list of non-null items: [!Blah]
59
- type_name << '!'
60
58
  type_path = field['type']['ofType']['ofType']['kind']
61
59
  type_name << field['type']['ofType']['ofType']['name']
62
60
  name_slug = field['type']['ofType']['ofType']['name']
61
+ # Nullable list of non-null items: [Blah!]
62
+ type_name << '!'
63
63
  else
64
64
  # Nullable list of nullable items: [Blah]
65
65
  type_path = field['type']['ofType']['kind']
@@ -1,3 +1,3 @@
1
1
  module GraphQLDocs
2
- VERSION = '0.4.0'
2
+ VERSION = '0.4.1'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: graphql-docs
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.0
4
+ version: 0.4.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Garen Torikian