Skip to content
This repository has been archived by the owner on Apr 3, 2024. It is now read-only.

Commit

Permalink
fix: return the original body if it does not appear to be JSON
Browse files Browse the repository at this point in the history
  • Loading branch information
Benjamin Coe committed Nov 22, 2017
1 parent eb849b8 commit a677f62
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/redact.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ const replacement = '[SECRET]'
module.exports = function (body) {
if (isPackageJson(body)) {
return body.replace(redactSSORegex, `"sso":"${replacement}"`)
} else {
return body
}
}

Expand Down

0 comments on commit a677f62

Please sign in to comment.