Skip to content

Commit

Permalink
Prevent bad formatted help context menu (#77)
Browse files Browse the repository at this point in the history
  • Loading branch information
uditdc authored Jan 9, 2023
1 parent 5580e29 commit e9f3b67
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ const parseCliResponse = (err: Error, argv: any, output: string) => {
let formattedOutput = output
formattedOutput = formattedOutput.replace(/\[boolean\]/g, '')

if (!!argv.help && !!argv._ && argv._.length > 0) {
if (!!argv.help && !!argv._ && argv._.length > 0 && !output.startsWith('bls [command] [subcommand]')) {
formattedOutput = formattedOutput.replace(/\s\sbls\s\w+\s/g, ' ')
}

Expand Down

0 comments on commit e9f3b67

Please sign in to comment.