@@ -137,13 +137,13 @@ instance HasFieldDefinitions '[] where
137
137
-- object types from union type lists, e.g. for
138
138
-- Union "Horse" '[Leg, Head, Tail]
139
139
-- ^ ^^^^^^^^^^^^^^^^^ this part
140
- class UnionTypeObjectTypeDefinitionList a where
140
+ class HasUnionTypeObjectTypeDefinitions a where
141
141
getUnionTypeObjectTypeDefinitions :: Either NameError [Schema. ObjectTypeDefinition ]
142
142
143
- instance forall a as . (HasObjectDefinition a , UnionTypeObjectTypeDefinitionList as ) => UnionTypeObjectTypeDefinitionList (a : as ) where
143
+ instance forall a as . (HasObjectDefinition a , HasUnionTypeObjectTypeDefinitions as ) => HasUnionTypeObjectTypeDefinitions (a : as ) where
144
144
getUnionTypeObjectTypeDefinitions = cons <$> getDefinition @ a <*> getUnionTypeObjectTypeDefinitions @ as
145
145
146
- instance UnionTypeObjectTypeDefinitionList '[] where
146
+ instance HasUnionTypeObjectTypeDefinitions '[] where
147
147
getUnionTypeObjectTypeDefinitions = pure []
148
148
149
149
-- Interfaces
@@ -265,7 +265,7 @@ instance forall ks enum. (KnownSymbol ks, GraphQLEnum enum) => HasAnnotatedType
265
265
let et = Schema. EnumTypeDefinition <$> name <*> map (map Schema. EnumValueDefinition ) enums
266
266
Schema. TypeNonNull . Schema. NonNullTypeNamed . Schema. DefinedType . Schema. TypeDefinitionEnum <$> et
267
267
268
- instance forall ks as . (KnownSymbol ks , UnionTypeObjectTypeDefinitionList as ) => HasAnnotatedType (Union ks as ) where
268
+ instance forall ks as . (KnownSymbol ks , HasUnionTypeObjectTypeDefinitions as ) => HasAnnotatedType (Union ks as ) where
269
269
getAnnotatedType =
270
270
let name = nameFromSymbol @ ks
271
271
types = Schema. NonEmptyList <$> getUnionTypeObjectTypeDefinitions @ as
0 commit comments