From 9951168b9b93d07195507aa5a919ea09333d6f53 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Benedikt=20R=C3=B6tsch?= Date: Wed, 5 Aug 2020 15:37:23 +0200 Subject: [PATCH] fix: use content type id by default to create reference gql types (#26102) --- packages/gatsby-source-contentful/src/gatsby-node.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/packages/gatsby-source-contentful/src/gatsby-node.js b/packages/gatsby-source-contentful/src/gatsby-node.js index 4641a3ed886f6..3d0cba4bebbb8 100644 --- a/packages/gatsby-source-contentful/src/gatsby-node.js +++ b/packages/gatsby-source-contentful/src/gatsby-node.js @@ -297,7 +297,11 @@ exports.sourceNodes = async ( if (entryList[i].length) { reporter.info( - `Creating ${entryList[i].length} Contentful ${contentTypeItem.name} nodes` + `Creating ${entryList[i].length} Contentful ${ + pluginConfig.get(`useNameForId`) + ? contentTypeItem.name + : contentTypeItem.sys.id + } nodes` ) }