Skip to content

Commit

Permalink
BAU Log error message when rendering error page
Browse files Browse the repository at this point in the history
If we catch an error and render the error page, we do not currently
log the error message. The `error` always evaluates as an empty
JSON object when we attempt to log it so it is not included. Instead,
log the error message.
  • Loading branch information
stephencdaly committed Feb 20, 2024
1 parent bcef229 commit 5ad9410
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/utils/response-router.js
Original file line number Diff line number Diff line change
Expand Up @@ -274,7 +274,7 @@ function logErrorPageShown (page, reason, loggingFields, error) {
logger.info('Rendering error response', {
page,
reason,
error,
error: error && error.message,
...loggingFields
})
}
Expand Down

0 comments on commit 5ad9410

Please sign in to comment.