Skip to content

Commit 3d10e29

Browse files
committed
Using StaticClassListTypeMapperFactory instead of non working GlobTypeMapper
1 parent d9e91ea commit 3d10e29

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

Resources/config/container/graphqlite.xml

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,11 +20,6 @@
2020
<call method="setAuthorizationService">
2121
<argument type="service" id="TheCodingMachine\GraphQLite\Security\AuthorizationServiceInterface" />
2222
</call>
23-
<!-- Ideally, we would not need to go through the GlobTypeMapper for types in packages. We shoul
24-
have the opportunity to add types / models through another class (like the AggregateControllerQueryProviderFactory for queries) -->
25-
<call method="addTypeNamespace">
26-
<argument type="string">TheCodingMachine\Graphqlite\Bundle\Types</argument>
27-
</call>
2823
</service>
2924

3025
<service id="TheCodingMachine\GraphQLite\Schema" public="true">
@@ -85,5 +80,12 @@
8580
<service id="TheCodingMachine\Graphqlite\Bundle\Controller\GraphQL\MeController" public="true" />
8681

8782
<service id="TheCodingMachine\Graphqlite\Bundle\Types\UserType" public="true"/>
83+
84+
<service id="TheCodingMachine\GraphQLite\Mappers\StaticClassListTypeMapperFactory">
85+
<argument type="collection">
86+
<argument>TheCodingMachine\Graphqlite\Bundle\Types\UserType</argument>
87+
</argument>
88+
<tag name="graphql.type_mapper_factory"/>
89+
</service>
8890
</services>
8991
</container>

0 commit comments

Comments
 (0)