Skip to content

Commit

Permalink
chore(scripts/pre-commit): fix type checking warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
jrolfs committed Jul 18, 2021
1 parent bd50ff9 commit d4cfa79
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/scripts/pre-commit.js
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ const lintStagedResult = spawn.sync(
{stdio: 'inherit'},
)

if (useCustomBuiltInConfig) {
if (useCustomBuiltInConfig && customBuiltInConfig) {
fs.rmdirSync(path.dirname(customBuiltInConfig), {recursive: true})
}

Expand All @@ -90,7 +90,7 @@ if (lintStagedResult.status === 0 && ifScript('validate')) {
stdio: 'inherit',
})

process.exit(validateResult.status)
process.exit(validateResult.status ?? 0)
} else {
process.exit(lintStagedResult.status)
process.exit(lintStagedResult.status ?? 0)
}

0 comments on commit d4cfa79

Please sign in to comment.