Skip to content

Commit

Permalink
Update packages/babel-parser/src/plugins/typescript/index.js
Browse files Browse the repository at this point in the history
Co-authored-by: Nicol貌 Ribaudo <nicolo.ribaudo@gmail.com>
  • Loading branch information
sosukesuzuki and nicolo-ribaudo committed Apr 3, 2021
1 parent 643ece6 commit 28e17fe
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/babel-parser/src/plugins/typescript/index.js
Expand Up @@ -573,7 +573,7 @@ export default (superClass: Class<Parser>): Class<Parser> =>
this.raise(this.state.pos, Errors.BadGetterArity);
}
} else if (method.kind === "set") {
if (method.parameters.length < 1) {
if (method.parameters.length !== 1) {
this.raise(this.state.pos, Errors.BadSetterArity);
}
if (method.typeAnnotation) {
Expand Down

0 comments on commit 28e17fe

Please sign in to comment.