Skip to content

Commit

Permalink
fix(rate-limit): --help is not a usage, fix #772
Browse files Browse the repository at this point in the history
  • Loading branch information
shigma committed Aug 13, 2022
1 parent bf39c27 commit e80defc
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
2 changes: 0 additions & 2 deletions build/.eslintrc.yml

This file was deleted.

3 changes: 2 additions & 1 deletion plugins/a11y/rate-limit/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,8 @@ export function apply(ctx: Context) {

let isUsage = true
for (const { name, notUsage } of Object.values(command._options)) {
if (name in options && notUsage) isUsage = false
// --help is not a usage (#772)
if (name in options && (notUsage || name === 'help')) isUsage = false
}

// check usage
Expand Down

0 comments on commit e80defc

Please sign in to comment.