Skip to content

Commit a1547a2

Browse files
authored
Merge pull request #6 from lsafer-meemer/main
fix(graphql-java): getter blocks wrong cast
2 parents 1febf33 + b7ef326 commit a1547a2

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

  • graphql-java/src/main/kotlin/internal

graphql-java/src/main/kotlin/internal/Types.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -369,11 +369,11 @@ fun <T : Any> TransformContext.addObjectType(
369369
val allInterfaces = type.generateAllInterfacesSequence().toList()
370370

371371
@Suppress("UNCHECKED_CAST")
372-
val allGetterBlocks = (allInterfaces.map { it.onGetBlocks } + type.onGetBlocks)
372+
val allGetterBlocks = (allInterfaces.flatMap { it.onGetBlocks } + type.onGetBlocks)
373373
as List<GraphQLGetterBlock<T, *>>
374374

375375
@Suppress("UNCHECKED_CAST")
376-
val allGetterBlockingBlocks = (allInterfaces.map { it.onGetBlockingBlocks } + type.onGetBlockingBlocks)
376+
val allGetterBlockingBlocks = (allInterfaces.flatMap { it.onGetBlockingBlocks } + type.onGetBlockingBlocks)
377377
as List<GraphQLGetterBlockingBlock<T, *>>
378378

379379
val allFields = (allInterfaces.flatMap { it.fields } + type.fields)

0 commit comments

Comments
 (0)