Skip to content

Commit d7a2ea6

Browse files
authored
back to reduce (d4rekanguok#38)
1 parent 1f9d9a5 commit d7a2ea6

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

packages/gatsby-plugin-graphql-codegen/src/graphql-codegen.config.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,9 @@ const createConfig: CreateConfig = async ({
4444
})
4545
})
4646
const results = await Promise.all(docPromises)
47-
const documents = results.filter(isSource).flat()
47+
const documents = results
48+
.filter(isSource)
49+
.reduce((acc, cur) => acc.concat(cur), [])
4850

4951
return {
5052
filename: pathToFile,

0 commit comments

Comments
 (0)