Skip to content

Commit

Permalink
fix(gatsby-source-wordpress): only log out duplicate node if we have …
Browse files Browse the repository at this point in the history
…all the data we want to log (#30751)
  • Loading branch information
TylerBarnes committed Apr 8, 2021
1 parent 1a9b830 commit 2bdd5a5
Showing 1 changed file with 7 additions and 4 deletions.
Expand Up @@ -115,11 +115,14 @@ const paginatedWpNodeFetch = async ({
)
)
}
helpers.reporter.info(
formatLogMessage(
`#${node.databaseId} (${node?.uri}) is a duplicate of ${existingNode.databaseId} (${existingNode?.uri})`

if (node?.databaseId && node?.uri && existingNode?.uri) {
helpers.reporter.info(
formatLogMessage(
`#${node.databaseId} (${node.uri}) is a duplicate of ${existingNode.databaseId} (${existingNode.uri})`
)
)
)
}
}
} else {
idSet.add(node.id)
Expand Down

0 comments on commit 2bdd5a5

Please sign in to comment.