Skip to content

Commit

Permalink
Fix JSON parse error in search when http request fails
Browse files Browse the repository at this point in the history
  • Loading branch information
ydshah2 committed May 12, 2020
1 parent 7b4f68d commit 5de6534
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ function apiCall(config, endpoint, method, params, callback) {
return callback('Access token invalid. If you created or changed your password recently, ' +
'please run \'logdna login\' again. Type \'logdna --help\' for more info.');
}
return callback('Error: ' + body.error || error);
return callback('Error: ' + error || body.error);
}
callback(null, body);
});
Expand Down

0 comments on commit 5de6534

Please sign in to comment.