Skip to content

Commit

Permalink
Fix exception handler
Browse files Browse the repository at this point in the history
  • Loading branch information
alexbassy committed Aug 10, 2017
1 parent b6c056a commit b215a10
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/gatsby-source-wordpress/src/gatsby-node.js
Original file line number Diff line number Diff line change
Expand Up @@ -228,15 +228,15 @@ function httpExceptionHandler (e) {
colorized.color.Font.FgRed
)
)
if (message != undefined) {
if (message) {
console.log(
colorized.out(
`Inner exception message : "${message}"`,
colorized.color.Font.FgRed
)
)
}
if ([400, 401, 402, 403].indexOf(status !== 'undefined')) {
if ([400, 401, 402, 403].includes(status)) {
console.log(
colorized.out(
`Auth on endpoint is not implemented on this gatsby-source plugin.`,
Expand Down

0 comments on commit b215a10

Please sign in to comment.